aboutsummaryrefslogtreecommitdiff
path: root/src/ast.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/ast.rs')
-rw-r--r--src/ast.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/ast.rs b/src/ast.rs
index e254c65..24c7125 100644
--- a/src/ast.rs
+++ b/src/ast.rs
@@ -68,6 +68,9 @@ pub enum Signature {
#[display("Set")]
Set,
+ #[display("⟨{_0}⟩")]
+ FromSet(Set),
+
#[display("theory {{ {} }}", _0.iter().map(|f| f.to_string()).collect::<Vec<_>>().join(" , "))]
Theory(Vec<Field<Signature>>),
@@ -126,7 +129,7 @@ pub enum Element {
element: Box<Element>,
},
- #[display("case {} of {{ {} }}", scrutinee, arms.iter().map(|a| a.to_string()).collect::<Vec<_>>().join(" | "))]
+ #[display("case {scrutinee} of [ {} ]", arms.iter().map(|a| a.to_string()).collect::<Vec<_>>().join(" | "))]
Case {
scrutinee: Box<Element>,
arms: Vec<CaseArm<Element>>,
@@ -147,6 +150,9 @@ pub enum Instance {
#[display("({_0} :: Set)")]
SetCoerce(Box<Set>),
+ #[display("⟨{_0}⟩")]
+ ElementCoerce(Element),
+
#[display("{_0}")]
Var(String),
@@ -171,7 +177,7 @@ pub enum Instance {
field: String,
},
- #[display("case {} of [ {} ]", scrutinee, arms.iter().map(|a| a.to_string()).collect::<Vec<_>>().join(" | "))]
+ #[display("case {scrutinee} of [ {} ]", arms.iter().map(|a| a.to_string()).collect::<Vec<_>>().join(" | "))]
Case {
scrutinee: Box<Element>,
arms: Vec<CaseArm<Instance>>,