Skip to content

Commit 6e51502

Browse files
committed
Handle Ast::Discard when building the scope tree.
1 parent fd07efb commit 6e51502

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

spec/examples/discard

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
component Main {
2+
fun render : String {
3+
case "A" {
4+
"A" => "A"
5+
_ => "X"
6+
}
7+
}
8+
}

src/scope.cr

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,7 @@ module Mint
218218
Ast::Variable,
219219
Ast::Builtin,
220220
Ast::Comment,
221+
Ast::Discard,
221222
Ast::Env
222223
when Ast::StringLiteral,
223224
Ast::HereDocument,

0 commit comments

Comments
 (0)