fixed more leaks

This commit is contained in:
nora 2021-12-30 20:07:27 +01:00
parent 1ad5ea7477
commit e58e6e3dc4
6 changed files with 31 additions and 38 deletions

View file

@ -4,12 +4,12 @@
//! All AST nodes are bump allocated into the lifetime `'ast`
use crate::errors::Span;
use crate::value::Symbol;
use crate::value::AstSymbol;
use bumpalo::collections::Vec;
#[derive(Debug, PartialEq, Eq, Hash)]
pub struct Ident<'ast> {
pub sym: Symbol<'ast>,
pub sym: AstSymbol<'ast>,
pub span: Span,
}
@ -112,7 +112,7 @@ impl Expr<'_> {
#[derive(Debug, PartialEq)]
pub enum Literal<'ast> {
String(String, Span),
String(&'ast str, Span),
Number(f64, Span),
Array(Vec<'ast, Expr<'ast>>, Span),
Object(Span),