Print bare data constructor

This commit is contained in:
greg 2018-06-12 20:44:20 -07:00
parent 3f2fff276c
commit 196954326e

View File

@ -77,6 +77,7 @@ impl Expr {
UserDefined { name: None, .. } => format!("<function>"), UserDefined { name: None, .. } => format!("<function>"),
UserDefined { name: Some(name), .. } => format!("<function {}>", name), UserDefined { name: Some(name), .. } => format!("<function {}>", name),
}, },
Expr::Constructor { name } => format!("<constructor {}>", name),
Expr::Tuple(exprs) => paren_wrapped_vec(exprs), Expr::Tuple(exprs) => paren_wrapped_vec(exprs),
_ => format!("{:?}", self), _ => format!("{:?}", self),
} }