Add ternary expressions to javascript grammar
This commit is contained in:
parent
5313bb5257
commit
7be8d469b8
4 changed files with 6912 additions and 6019 deletions
9
spec/runtime/languages/javascript/operators.txt
Normal file
9
spec/runtime/languages/javascript/operators.txt
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
==========================================
|
||||
parses ternary expressions
|
||||
==========================================
|
||||
print(isDone() ? stuff : otherStuff);
|
||||
---
|
||||
(program (expression_statement
|
||||
(function_call
|
||||
(identifier)
|
||||
(ternary (function_call (identifier)) (identifier) (identifier)))))
|
||||
Loading…
Add table
Add a link
Reference in a new issue