@@ -1150,24 +1150,23 @@ module Trees {
11501150
11511151 private class RedoStmtTree extends LeafTree , RedoStmt { }
11521152
1153- private class RescueModifierTree extends PreOrderTree , RescueModifierExpr {
1153+ private class RescueModifierTree extends PostOrderTree , RescueModifierExpr {
11541154 final override predicate propagatesAbnormal ( AstNode child ) { child = this .getHandler ( ) }
11551155
1156- final override predicate last ( AstNode last , Completion c ) {
1157- last ( this .getBody ( ) , last , c ) and
1158- not c instanceof RaiseCompletion
1159- or
1160- last ( this .getHandler ( ) , last , c )
1161- }
1156+ final override predicate first ( AstNode first ) { first ( this .getBody ( ) , first ) }
11621157
11631158 final override predicate succ ( AstNode pred , AstNode succ , Completion c ) {
1164- pred = this and
1165- first ( this .getBody ( ) , succ ) and
1166- c instanceof SimpleCompletion
1167- or
11681159 last ( this .getBody ( ) , pred , c ) and
1169- c instanceof RaiseCompletion and
1170- first ( this .getHandler ( ) , succ )
1160+ (
1161+ c instanceof RaiseCompletion and
1162+ first ( this .getHandler ( ) , succ )
1163+ or
1164+ not c instanceof RaiseCompletion and
1165+ succ = this
1166+ )
1167+ or
1168+ last ( this .getHandler ( ) , pred , c ) and
1169+ succ = this
11711170 }
11721171 }
11731172
0 commit comments