Skip to content

Commit 7eb9cab

Browse files
bors[bot]matklad
andauthored
Merge #40
40: Blocks3 r=matklad a=matklad Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2 parents 32088df + 91eb93c commit 7eb9cab

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "ungrammar"
33
description = "A DSL for describing concrete syntax trees"
4-
version = "1.14.4"
4+
version = "1.14.5"
55
license = "MIT OR Apache-2.0"
66
repository = "https://github.com/matklad/ungrammar"
77
edition = "2018"

rust.ungram

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ LetStmt =
318318
'=' initializer:Expr ';'
319319

320320
ExprStmt =
321-
Attr* Expr ';'?
321+
Expr ';'?
322322

323323
Expr =
324324
ArrayExpr
@@ -331,7 +331,6 @@ Expr =
331331
| CastExpr
332332
| ClosureExpr
333333
| ContinueExpr
334-
| EffectExpr
335334
| FieldExpr
336335
| ForExpr
337336
| IfExpr
@@ -366,7 +365,7 @@ Literal =
366365
PathExpr =
367366
Attr* Path
368367

369-
BlockExpr =
368+
StmtList =
370369
'{'
371370
Attr*
372371
statements:Stmt*
@@ -379,8 +378,8 @@ RefExpr =
379378
TryExpr =
380379
Attr* Expr '?'
381380

382-
EffectExpr =
383-
Attr* Label? ('try' | 'unsafe' | 'async' | 'const') BlockExpr
381+
BlockExpr =
382+
Attr* Label? ('try' | 'unsafe' | 'async' | 'const') StmtList
384383

385384
PrefixExpr =
386385
Attr* op:('-' | '!' | '*') Expr

0 commit comments

Comments
 (0)