Module: JPTGRAMMAR::TestExpr2

Defined in:
lib/parser/jptgrammar.rb

Instance Method Summary collapse

Instance Method Details

#astObject



2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
# File 'lib/parser/jptgrammar.rb', line 2462

def ast
  nest_ast = elements[1].ast
  if nest_ast[0] == "func"
    declared_as(nest_ast, :logical, " in test expression")
  end
  if elements[0].text_value == ''
    nest_ast
  else
    ["not", nest_ast]
  end
end