Fix bug with empty blocks
This commit is contained in:
parent
37b9560ee3
commit
e616dcd453
|
@ -236,7 +236,7 @@
|
||||||
(case (token-type parser)
|
(case (token-type parser)
|
||||||
::token/rbrace (let [es (add-member exprs current_expr)]
|
::token/rbrace (let [es (add-member exprs current_expr)]
|
||||||
(if (empty? es)
|
(if (empty? es)
|
||||||
(panic parser "Blocks must have at least one expression")
|
(advance (panic parser "Blocks must have at least one expression"))
|
||||||
(assoc (advance parser) ::ast {
|
(assoc (advance parser) ::ast {
|
||||||
::ast/type ::ast/block
|
::ast/type ::ast/block
|
||||||
:exprs es
|
:exprs es
|
||||||
|
|
Loading…
Reference in New Issue
Block a user