mirror of
https://github.com/zaphar/ucg.git
synced 2025-07-22 18:19:54 -04:00
DEV: Translate fails into the Bang opcode.
This commit is contained in:
parent
8c39c3826c
commit
f9c3ebeb50
@ -188,7 +188,10 @@ impl AST {
|
|||||||
Expression::Grouped(expr, _) => {
|
Expression::Grouped(expr, _) => {
|
||||||
Self::translate_expr(*expr, &mut ops);
|
Self::translate_expr(*expr, &mut ops);
|
||||||
}
|
}
|
||||||
Expression::Fail(_) => unimplemented!("Fail expressions are not implmented yet"),
|
Expression::Fail(def) => {
|
||||||
|
Self::translate_expr(*def.message, &mut ops);
|
||||||
|
ops.push(Op::Bang);
|
||||||
|
}
|
||||||
Expression::Format(def) => {
|
Expression::Format(def) => {
|
||||||
// TODO(jwall): It would actually be safer if this was happening
|
// TODO(jwall): It would actually be safer if this was happening
|
||||||
// when we create the format def instead of here.
|
// when we create the format def instead of here.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user