feat(xatu): add let order rule
This commit is contained in:
@@ -29,6 +29,7 @@ impl std::fmt::Display for SourceRange {
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub enum NodeData {
|
||||
Binding(Binding),
|
||||
LetBlock(LetBlock),
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
@@ -37,6 +38,18 @@ pub struct Binding {
|
||||
pub value: Expr,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct LetBlock {
|
||||
pub bindings: Vec<LetBinding>,
|
||||
pub body_references: Vec<Ident>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct LetBinding {
|
||||
pub name: Ident,
|
||||
pub references: Vec<Ident>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Eq)]
|
||||
pub struct Ident {
|
||||
pub name: String,
|
||||
|
||||
Reference in New Issue
Block a user