diff --git a/compiler/parser/src/parser/file.rs b/compiler/parser/src/parser/file.rs index 7e0978d2d8..90810f29c0 100644 --- a/compiler/parser/src/parser/file.rs +++ b/compiler/parser/src/parser/file.rs @@ -146,8 +146,8 @@ impl ParserContext<'_> { while self.has_next() { match &self.token.token { Token::Const => { - let definition = self.parse_const_declaration_statement()?; - consts.push((Symbol::intern(&definition.place.to_string()), definition)); + let declaration = self.parse_const_declaration_statement()?; + consts.push((Symbol::intern(&declaration.place.to_string()), definition)); } Token::Struct | Token::Record => { let (id, struct_) = self.parse_struct()?;