Unsafe lifetime

This commit is contained in:
2026-06-16 03:59:28 +02:00
parent d7e5e72bbb
commit f07bde8d3f
5 changed files with 48 additions and 10 deletions
+7 -1
View File
@@ -17,10 +17,16 @@ pub struct Identifier(pub String);
#[derive(Debug, Clone, Serialize, Default)]
pub struct ParamList(pub Vec<VarDecl>);
#[derive(Debug, Clone, Serialize, PartialEq, Eq, Hash)]
pub enum Lifetime {
Lifetime(Identifier),
Unsafe,
}
#[derive(Debug, Clone, Serialize, PartialEq, Eq, Hash)]
pub enum TypeExpr {
Ref {
lifetime: Option<Identifier>,
lifetime: Option<Lifetime>,
mutable: bool,
ty: Box<TypeExpr>,
},