summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Andreas Benkard <matthias@benkard.de>2008-06-12 22:14:26 +0200
committerMatthias Andreas Benkard <matthias@benkard.de>2008-06-12 22:14:26 +0200
commit2f8225195b95aaed2c45c0daf582104657114ec4 (patch)
treefbde12b19e028dcd66748dd037af2ce98fda21c3
parentfaefa40e18b8bbb283761c67305ba6ed7b346a3c (diff)
MLKDynamicContext: Add support for catch tags.
-rw-r--r--MLKDynamicContext.h2
-rw-r--r--MLKDynamicContext.m2
2 files changed, 4 insertions, 0 deletions
diff --git a/MLKDynamicContext.h b/MLKDynamicContext.h
index f515901..ba67ad8 100644
--- a/MLKDynamicContext.h
+++ b/MLKDynamicContext.h
@@ -8,6 +8,7 @@
{
MLKEnvironment *_conditionHandlers;
MLKEnvironment *_restarts;
+ MLKEnvironment *_catchTags;
MLKClosure *_currentConditionHandler;
MLKEnvironment *_environment;
MLKDynamicContext *_parent;
@@ -17,6 +18,7 @@
variables:(NSDictionary *)vars
handlers:(NSDictionary *)handlers
restarts:(NSDictionary *)restarts
+ catchTags:(NSDictionary *)catchTags
currentHandler:(MLKClosure *)handler;
-(MLKDynamicContext *) pushContext;
diff --git a/MLKDynamicContext.m b/MLKDynamicContext.m
index 2d8312f..ed4357a 100644
--- a/MLKDynamicContext.m
+++ b/MLKDynamicContext.m
@@ -25,6 +25,7 @@
variables:(NSDictionary *)vars
handlers:(NSDictionary *)handlers
restarts:(NSDictionary *)restarts
+ catchTags:(NSDictionary *)catchTags
currentHandler:(MLKClosure *)handler
{
_parent = (aContext ? aContext : [MLKDynamicContext currentContext]);
@@ -33,6 +34,7 @@
_parent,
_parent->_conditionHandlers);
_restarts = MAKE_ENVIRONMENT(restarts, _parent, _parent->_restarts);
+ _catchTags = MAKE_ENVIRONMENT(catchTags, _parent, _parent->_catchTags);
_currentConditionHandler = (handler
? (id) handler
: (_parent