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

Method CloseComplexValue

library/cpp/json/json_reader.cpp:47–68  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45 }
46
47 bool TParserCallbacks::CloseComplexValue() {
48 if (ValuesStack.empty()) {
49 return false;
50 }
51
52 ValuesStack.pop_back();
53 if (!ValuesStack.empty()) {
54 switch (ValuesStack.back()->GetType()) {
55 case JSON_ARRAY:
56 CurrentState = IN_ARRAY;
57 break;
58 case JSON_MAP:
59 CurrentState = IN_MAP;
60 break;
61 default:
62 return false;
63 }
64 } else {
65 CurrentState = FINISH;
66 }
67 return true;
68 }
69
70 TParserCallbacks::TParserCallbacks(TJsonValue& value, bool throwOnError, bool notClosedBracketIsError)
71 : TJsonCallbacks(throwOnError)

Callers

nothing calls this directly

Calls 4

emptyMethod · 0.45
pop_backMethod · 0.45
GetTypeMethod · 0.45
backMethod · 0.45

Tested by

no test coverage detected