diff options
| author | Bruce Hill <bruce@bruce-hill.com> | 2024-04-17 13:44:01 -0400 |
|---|---|---|
| committer | Bruce Hill <bruce@bruce-hill.com> | 2024-04-17 13:44:01 -0400 |
| commit | e98f6854f5995c42d16641cee0281dacde4cc25c (patch) | |
| tree | 1d02575949b9335a36853d0c00bc4e92a5b5e8bb /parse.c | |
| parent | 35339e2aa028942d297f15521c26e1400fe1eca2 (diff) | |
Use leading underscore for file-local variables and functions instead of
"private" keyword
Diffstat (limited to 'parse.c')
| -rw-r--r-- | parse.c | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -1824,7 +1824,7 @@ PARSER(parse_func_def) { arg_ast_t *args = parse_args(ctx, &pos, false); whitespace(&pos); - bool is_inline = false, is_private = false; + bool is_inline = false; ast_t *cache_ast = NULL; for (bool specials = match(&pos, ";"); specials; specials = match_separator(&pos)) { const char *flag_start = pos; @@ -1837,8 +1837,6 @@ PARSER(parse_func_def) { parser_err(ctx, flag_start, pos, "I expected a value for 'cache_size'"); whitespace(&pos); cache_ast = expect(ctx, start, &pos, parse_expr, "I expected a maximum size for the cache"); - } else if (match_word(&pos, "private")) { - is_private = true; } } expect_closing(ctx, &pos, ")", "I wasn't able to parse the rest of this function definition"); @@ -1852,7 +1850,7 @@ PARSER(parse_func_def) { "This function needs a body block"); return NewAST(ctx->file, start, pos, FunctionDef, .name=name, .args=args, .ret_type=ret_type, .body=body, .cache=cache_ast, - .is_inline=is_inline, .is_private=is_private); + .is_inline=is_inline); } PARSER(parse_extern) { |
