KCL: If-else expressions (#4022)

Closes https://github.com/KittyCAD/modeling-app/issues/3677

You can review each commit separately, they're neat commits with logical purpose in each.

Future enhancements:

- https://github.com/KittyCAD/modeling-app/issues/4015
- https://github.com/KittyCAD/modeling-app/issues/4020
- Right now the parser errors are not very good, especially if you forget to put an expression in the end of an if/else block
This commit is contained in:
Adam Chalmers
2024-09-30 15:40:50 -05:00
committed by GitHub
parent 6dfadbea18
commit 125207f60c
12 changed files with 897 additions and 22 deletions

View File

@ -90,4 +90,9 @@ gen_test_fail!(
"semantic: cannot use % outside a pipe expression"
);
gen_test!(sketch_in_object);
gen_test!(if_else);
// gen_test_fail!(
// if_else_no_expr,
// "syntax: blocks inside an if/else expression must end in an expression"
// );
gen_test!(add_lots);