@@ -3358,28 +3358,27 @@ compiler_while(struct compiler *c, stmt_ty s)
3358
3358
NEW_JUMP_TARGET_LABEL (c , anchor );
3359
3359
3360
3360
USE_LABEL (c , loop );
3361
- if (compiler_push_fblock (c , LOC (s ), WHILE_LOOP , loop , end , NULL ) < 0 ) {
3362
- return 0 ;
3363
- }
3361
+
3362
+ RETURN_IF_ERROR (compiler_push_fblock (c , LOC (s ), WHILE_LOOP , loop , end , NULL ));
3364
3363
if (!compiler_jump_if (c , LOC (s ), s -> v .While .test , anchor , 0 )) {
3365
- return 0 ;
3364
+ return ERROR ;
3366
3365
}
3367
3366
3368
3367
USE_LABEL (c , body );
3369
- _VISIT_SEQ (c , stmt , s -> v .While .body );
3368
+ VISIT_SEQ (c , stmt , s -> v .While .body );
3370
3369
if (!compiler_jump_if (c , LOC (s ), s -> v .While .test , body , 1 )) {
3371
- return 0 ;
3370
+ return ERROR ;
3372
3371
}
3373
3372
3374
3373
compiler_pop_fblock (c , WHILE_LOOP , loop );
3375
3374
3376
3375
USE_LABEL (c , anchor );
3377
3376
if (s -> v .While .orelse ) {
3378
- _VISIT_SEQ (c , stmt , s -> v .While .orelse );
3377
+ VISIT_SEQ (c , stmt , s -> v .While .orelse );
3379
3378
}
3380
3379
3381
3380
USE_LABEL (c , end );
3382
- return 1 ;
3381
+ return SUCCESS ;
3383
3382
}
3384
3383
3385
3384
static int
@@ -4226,7 +4225,7 @@ compiler_visit_stmt(struct compiler *c, stmt_ty s)
4226
4225
case For_kind :
4227
4226
return compiler_for (c , s ) == SUCCESS ? 1 : 0 ;
4228
4227
case While_kind :
4229
- return compiler_while (c , s );
4228
+ return compiler_while (c , s ) == SUCCESS ? 1 : 0 ;
4230
4229
case If_kind :
4231
4230
return compiler_if (c , s );
4232
4231
case Match_kind :
0 commit comments