summaryrefslogtreecommitdiff
path: root/src/syntax
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2021-12-20 14:18:29 +0100
committerLaurenz <laurmaedje@gmail.com>2021-12-21 00:20:24 +0100
commit11565a40b315212474f52eb576a9fd92b11f1132 (patch)
treec6b7afb35103065bc92b407094ca905bb75cfc73 /src/syntax
parent958f74f77707340f34ee36d09492bdb74523aa2a (diff)
Set Rules Episode IX: The Rise of Testing
Diffstat (limited to 'src/syntax')
-rw-r--r--src/syntax/ast.rs3
-rw-r--r--src/syntax/mod.rs2
2 files changed, 4 insertions, 1 deletions
diff --git a/src/syntax/ast.rs b/src/syntax/ast.rs
index 9190953f..ae8ecdc9 100644
--- a/src/syntax/ast.rs
+++ b/src/syntax/ast.rs
@@ -1,4 +1,6 @@
//! A typed layer over the red-green tree.
+//!
+//! The AST is rooted in the [`Markup`] node.
use std::ops::Deref;
@@ -283,6 +285,7 @@ impl Expr {
Self::Ident(_)
| Self::Call(_)
| Self::Let(_)
+ | Self::Set(_)
| Self::If(_)
| Self::While(_)
| Self::For(_)
diff --git a/src/syntax/mod.rs b/src/syntax/mod.rs
index b9b00487..d9ad42a8 100644
--- a/src/syntax/mod.rs
+++ b/src/syntax/mod.rs
@@ -187,7 +187,7 @@ impl From<GreenData> for Green {
impl Debug for GreenData {
fn fmt(&self, f: &mut Formatter) -> fmt::Result {
- write!(f, "{:?}: {}", self.kind, self.len())
+ write!(f, "{:?}: {}", self.kind, self.len)
}
}