diff --git a/lib/syntax_tree/node.rb b/lib/syntax_tree/node.rb index d153ef78..30fd8cf1 100644 --- a/lib/syntax_tree/node.rb +++ b/lib/syntax_tree/node.rb @@ -5192,7 +5192,7 @@ def call(q, node) else # Otherwise, we're going to check the conditional for certain cases. case node - in predicate: Assign | Command | CommandCall | MAssign | OpAssign + in predicate: Assign | Command | CommandCall | MAssign | Not | OpAssign false in { statements: { body: [truthy] }, diff --git a/test/fixtures/if.rb b/test/fixtures/if.rb index cabea4c3..607af05d 100644 --- a/test/fixtures/if.rb +++ b/test/fixtures/if.rb @@ -35,3 +35,9 @@ % if foo {} end +% +if not a + b +else + c +end