MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / yaml_parser_fetch_plain_scalar

Function yaml_parser_fetch_plain_scalar

external/libyaml/src/scanner.c:1906–1931  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1904 */
1905
1906static int
1907yaml_parser_fetch_plain_scalar(yaml_parser_t *parser)
1908{
1909 yaml_token_t token;
1910
1911 /* A plain scalar could be a simple key. */
1912
1913 if (!yaml_parser_save_simple_key(parser))
1914 return 0;
1915
1916 /* A simple key cannot follow a flow scalar. */
1917
1918 parser->simple_key_allowed = 0;
1919
1920 /* Create the SCALAR token and append it to the queue. */
1921
1922 if (!yaml_parser_scan_plain_scalar(parser, &token))
1923 return 0;
1924
1925 if (!ENQUEUE(parser, parser->tokens, token)) {
1926 yaml_token_delete(&token);
1927 return 0;
1928 }
1929
1930 return 1;
1931}
1932
1933/*
1934 * Eat whitespaces and comments until the next token is found.

Callers 1

Calls 3

yaml_token_deleteFunction · 0.85

Tested by

no test coverage detected