@@ -1559,32 +1559,31 @@ compiler_visit_argannotation(struct compiler *c, identifier id,
15591559 VISIT (c , expr , annotation );
15601560 mangled = _Py_Mangle (c -> u -> u_private , id );
15611561 if (!mangled )
1562- return -1 ;
1562+ return 0 ;
15631563 if (PyList_Append (names , mangled ) < 0 ) {
15641564 Py_DECREF (mangled );
1565- return -1 ;
1565+ return 0 ;
15661566 }
15671567 Py_DECREF (mangled );
15681568 }
1569- return 0 ;
1569+ return 1 ;
15701570}
15711571
15721572static int
15731573compiler_visit_argannotations (struct compiler * c , asdl_seq * args ,
15741574 PyObject * names )
15751575{
1576- int i , error ;
1576+ int i ;
15771577 for (i = 0 ; i < asdl_seq_LEN (args ); i ++ ) {
15781578 arg_ty arg = (arg_ty )asdl_seq_GET (args , i );
1579- error = compiler_visit_argannotation (
1579+ if (! compiler_visit_argannotation (
15801580 c ,
15811581 arg -> arg ,
15821582 arg -> annotation ,
1583- names );
1584- if (error )
1585- return error ;
1583+ names ))
1584+ return 0 ;
15861585 }
1587- return 0 ;
1586+ return 1 ;
15881587}
15891588
15901589static int
@@ -1604,16 +1603,16 @@ compiler_visit_annotations(struct compiler *c, arguments_ty args,
16041603 if (!names )
16051604 return -1 ;
16061605
1607- if (compiler_visit_argannotations (c , args -> args , names ))
1606+ if (! compiler_visit_argannotations (c , args -> args , names ))
16081607 goto error ;
16091608 if (args -> vararg && args -> vararg -> annotation &&
1610- compiler_visit_argannotation (c , args -> vararg -> arg ,
1609+ ! compiler_visit_argannotation (c , args -> vararg -> arg ,
16111610 args -> vararg -> annotation , names ))
16121611 goto error ;
1613- if (compiler_visit_argannotations (c , args -> kwonlyargs , names ))
1612+ if (! compiler_visit_argannotations (c , args -> kwonlyargs , names ))
16141613 goto error ;
16151614 if (args -> kwarg && args -> kwarg -> annotation &&
1616- compiler_visit_argannotation (c , args -> kwarg -> arg ,
1615+ ! compiler_visit_argannotation (c , args -> kwarg -> arg ,
16171616 args -> kwarg -> annotation , names ))
16181617 goto error ;
16191618
@@ -1622,7 +1621,7 @@ compiler_visit_annotations(struct compiler *c, arguments_ty args,
16221621 if (!return_str )
16231622 goto error ;
16241623 }
1625- if (compiler_visit_argannotation (c , return_str , returns , names )) {
1624+ if (! compiler_visit_argannotation (c , return_str , returns , names )) {
16261625 goto error ;
16271626 }
16281627
0 commit comments