File tree Expand file tree Collapse file tree 1 file changed +2
-6
lines changed
graalpython/com.oracle.graal.python/src/com/oracle/graal/python/nodes/statement Expand file tree Collapse file tree 1 file changed +2
-6
lines changed Original file line number Diff line number Diff line change @@ -255,23 +255,19 @@ protected static boolean test(TruffleObject receiver) {
255
255
256
256
protected static class CatchesFunction implements TruffleObject {
257
257
private final RootCallTarget isInstance ;
258
- private final PTuple caughtClasses ;
259
258
private final Object [] args = PArguments .create (2 );
260
259
261
260
CatchesFunction (RootCallTarget callTarget , PTuple caughtClasses ) {
262
261
this .isInstance = callTarget ;
263
- this . caughtClasses = caughtClasses ;
262
+ PArguments . setArgument ( args , 1 , caughtClasses ) ;
264
263
}
265
264
266
265
@ ExplodeLoop
267
266
boolean catches (Object exception ) {
268
267
if (exception instanceof PBaseException ) {
269
268
PArguments .setArgument (args , 0 , exception );
270
- PArguments .setArgument (args , 1 , caughtClasses );
271
269
try {
272
- if (isInstance .call (args ) == Boolean .TRUE ) {
273
- return true ;
274
- }
270
+ return isInstance .call (args ) == Boolean .TRUE ;
275
271
} catch (PException e ) {
276
272
}
277
273
}
You can’t perform that action at this time.
0 commit comments