Note: a static buffer is used here.
| 88 | |
| 89 | // Note: a static buffer is used here. |
| 90 | RET parse_punct(PARAMS, int punct) { |
| 91 | static char punctbuf[16]; |
| 92 | struct graphql_token *tok = list_top(tokens, struct graphql_token, node); |
| 93 | if (!tok || tok->token_type != punct) { |
| 94 | if (punct == PUNCT_SPREAD) |
| 95 | sprintf(punctbuf, "expected: '...'"); |
| 96 | else |
| 97 | sprintf(punctbuf, "expected: '%c'", punct); |
| 98 | *err = punctbuf; return NULL; |
| 99 | } |
| 100 | CONSUME_ONE; |
| 101 | return tok; |
| 102 | } |
| 103 | |
| 104 | RET parse_name(PARAMS) { |
| 105 | struct graphql_token *tok = list_top(tokens, struct graphql_token, node); |
no outgoing calls
no test coverage detected