aboutsummaryrefslogtreecommitdiff
path: root/src/boot/parser.boot
diff options
context:
space:
mode:
authordos-reis <gdr@axiomatics.org>2008-02-15 19:42:51 +0000
committerdos-reis <gdr@axiomatics.org>2008-02-15 19:42:51 +0000
commit9d17d5a9314c999f1495392909dbfdb09b0dc1e3 (patch)
tree738980ea24ed7afb96b64d7fdff44c985db0dd12 /src/boot/parser.boot
parent933e278d8db01dee8e057ecdab6a1b91a79c45de (diff)
downloadopen-axiom-9d17d5a9314c999f1495392909dbfdb09b0dc1e3.tar.gz
* boot/parser.boot (bpSimpleCatch): New.
(bTry): Use it. * boot/strap: Update.
Diffstat (limited to 'src/boot/parser.boot')
-rw-r--r--src/boot/parser.boot10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/boot/parser.boot b/src/boot/parser.boot
index 1c4fd348..fc21f148 100644
--- a/src/boot/parser.boot
+++ b/src/boot/parser.boot
@@ -650,17 +650,23 @@ bpThrow() ==
bpEqKey "THROW" and bpApplication() and
bpPush bfThrow bpPop1()
+++ Try:
+++ try Assign CatchItems
bpTry() ==
bpEqKey "TRY" and bpAssign() and
(bpEqKey "BACKSET" or true) and
(bpEqKey "CATCH" or bpMissing "CATCH") and
- (bpPiledCatchItems() or bpName() or bpTrap()) and
+ (bpPiledCatchItems() or bpSimpleCatch() or bpTrap()) and
bpPush bfTry(bpPop2(), bpPop1())
+++ SimpleCatch:
+++ catch Name
+bpSimpleCatch() ==
+ bpCatchItem() and bpPush [bpPop1()]
+
bpPiledCatchItems() ==
bpPileBracketed function bpCatchItemList
-
bpCatchItemList() ==
bpListAndRecover function bpCatchItem