made catch optional

This commit is contained in:
satyr
2010-10-05 05:53:32 +09:00
parent ae55c70ac5
commit d85910c17f
6 changed files with 91 additions and 81 deletions

View File

@@ -389,6 +389,7 @@ grammar =
# The variants of *try/catch/finally* exception handling blocks.
Try: [
o "TRY Block", -> new TryNode $2
o "TRY Block Catch", -> new TryNode $2, $3[0], $3[1]
o "TRY Block FINALLY Block", -> new TryNode $2, null, null, $4
o "TRY Block Catch FINALLY Block", -> new TryNode $2, $3[0], $3[1], $5