src/JavaContext.st
branchjk_new_structure
changeset 1461 34a9c99d0295
parent 1459 9e24f4337d78
child 1476 1f960ed67758
--- a/src/JavaContext.st	Mon Apr 09 09:54:09 2012 +0000
+++ b/src/JavaContext.st	Tue Apr 10 10:21:41 2012 +0000
@@ -78,6 +78,21 @@
 
     "Modified: / 13-12-1995 / 19:05:22 / cg"
     "Modified: / 25-10-2010 / 17:19:23 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+shouldExecuteFinallyOnUnwind
+    "Return true, if a finally block should be executed
+     upon force unwind"
+
+    | m pc |
+
+    m := self method.
+    pc := self pc.
+    self assert: m notNil.
+    m hasFinally ifFalse:[ ^ false ].
+    ^(method handlerFor: nil at: pc) notNil.
+
+    "Created: / 10-04-2012 / 11:09:01 / Jan Vrany <jan.vrany@fit.cvut.cz>"
 ! !
 
 !JavaContext methodsFor:'ST context mimicri'!