MCPcopy Create free account
hub / github.com/catboost/catboost / ToSharedRef

Method ToSharedRef

library/cpp/yt/yson_string/string.cpp:145–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

143}
144
145TSharedRef TYsonString::ToSharedRef() const
146{
147 return Visit(
148 Payload_,
149 [] (const TNullPayload&) -> TSharedRef {
150 YT_ABORT();
151 },
152 [&] (const TSharedRangeHolderPtr& holder) {
153 return TSharedRef(Begin_, Size_, holder);
154 },
155 [] (const TCowString& payload) {
156 return TSharedRef::FromString(payload);
157 });
158}
159
160size_t TYsonString::ComputeHash() const
161{

Callers

nothing calls this directly

Calls 3

VisitFunction · 0.85
TSharedRefClass · 0.85
FromStringFunction · 0.50

Tested by

no test coverage detected