diff --git a/compiler/lex.c b/compiler/lex.c index a7b8eeb..0c18e4b 100644 --- a/compiler/lex.c +++ b/compiler/lex.c @@ -248,7 +248,7 @@ identifier(LexState *ls) backup(ls, 1); token.id = T_IDENT; - token.ident = (Str){intern_identifier(ls, ident_buf), i}; + token.ident = Str_from_buf(intern_identifier(ls, ident_buf), i); token.len = i; return token; }