MCPcopy Create free account
hub / github.com/apache/trafficserver / ScanKey

Method ScanKey

lib/yamlcpp/src/scantoken.cpp:173–189  ·  view source on GitHub ↗

Key

Source from the content-addressed store, hash-verified

171
172// Key
173void Scanner::ScanKey() {
174 // handle keys differently in the block context (and manage indents)
175 if (InBlockContext()) {
176 if (!m_simpleKeyAllowed)
177 throw ParserException(INPUT.mark(), ErrorMsg::MAP_KEY);
178
179 PushIndentTo(INPUT.column(), IndentMarker::MAP);
180 }
181
182 // can only put a simple key here if we're in block context
183 m_simpleKeyAllowed = InBlockContext();
184
185 // eat
186 Mark mark = INPUT.mark();
187 INPUT.eat(1);
188 m_tokens.push(Token(Token::KEY, mark));
189}
190
191// Value
192void Scanner::ScanValue() {

Callers

nothing calls this directly

Calls 6

ParserExceptionFunction · 0.85
eatMethod · 0.80
TokenClass · 0.70
markMethod · 0.45
columnMethod · 0.45
pushMethod · 0.45

Tested by

no test coverage detected