diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-05-03 12:57:43 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-05-03 12:57:43 +0900 |
| commit | 22649829cd7b6d8f5e7b630167b1a928e5275f05 (patch) | |
| tree | fefdbdfd17d8cb2917a28dc95a2622556dfbb39e /src | |
| parent | 3b1a2de0ae0a7f8e25e348df43213fd6bf2ef0d4 (diff) | |
| download | ducc-22649829cd7b6d8f5e7b630167b1a928e5275f05.tar.gz ducc-22649829cd7b6d8f5e7b630167b1a928e5275f05.tar.zst ducc-22649829cd7b6d8f5e7b630167b1a928e5275f05.zip | |
chore: rename variables
Diffstat (limited to 'src')
| -rw-r--r-- | src/parse.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/parse.c b/src/parse.c index f7fec94..b95bc1e 100644 --- a/src/parse.c +++ b/src/parse.c @@ -1762,7 +1762,7 @@ static AstNode* parse_init_declarator(Parser* p, Type* ty) { // 'struct' TODO attribute-specifier-sequence? identifier? '{' member-declaration-list '}' // 'struct' TODO attribute-specifier-sequence? identifier static Type* parse_struct_specifier(Parser* p) { - SourceLocation struct_kw_pos = peek_token(p)->loc; + SourceLocation struct_kw_loc = current_location(p); next_token(p); const Token* name; @@ -1772,7 +1772,7 @@ static Type* parse_struct_specifier(Parser* p) { Token* anonymous_token = calloc(1, sizeof(Token)); anonymous_token->kind = TokenKind_ident; anonymous_token->value.string = anonymous_name; - anonymous_token->loc = struct_kw_pos; + anonymous_token->loc = struct_kw_loc; name = anonymous_token; } else { name = parse_ident(p); @@ -1823,7 +1823,7 @@ static Type* parse_struct_specifier(Parser* p) { // 'union' TODO attribute-specifier-sequence? identifier? '{' member-declaration-list '}' // 'union' TODO attribute-specifier-sequence? identifier static Type* parse_union_specifier(Parser* p) { - SourceLocation union_kw_pos = peek_token(p)->loc; + SourceLocation union_kw_loc = current_location(p); next_token(p); const Token* name; @@ -1833,7 +1833,7 @@ static Type* parse_union_specifier(Parser* p) { Token* anonymous_token = calloc(1, sizeof(Token)); anonymous_token->kind = TokenKind_ident; anonymous_token->value.string = anonymous_name; - anonymous_token->loc = union_kw_pos; + anonymous_token->loc = union_kw_loc; name = anonymous_token; } else { name = parse_ident(p); @@ -2133,7 +2133,7 @@ static AstNode* parse_member_declarator(Parser* p, Type* base_ty) { // 'enum' TODO attribute-specifier-sequence? identifier? TODO enum-type-specifier? '{' enumerator-list ','? '}' // 'enum' identifier TODO enum-type-specifier? static Type* parse_enum_specifier(Parser* p) { - SourceLocation enum_kw_pos = peek_token(p)->loc; + SourceLocation enum_kw_loc = current_location(p); next_token(p); const Token* name; @@ -2143,7 +2143,7 @@ static Type* parse_enum_specifier(Parser* p) { Token* anonymous_token = calloc(1, sizeof(Token)); anonymous_token->kind = TokenKind_ident; anonymous_token->value.string = anonymous_name; - anonymous_token->loc = enum_kw_pos; + anonymous_token->loc = enum_kw_loc; name = anonymous_token; } else { name = parse_ident(p); |
