|
const_tuple_str_plain_empty_tuple = PyTuple_New( 1 ); |
|
const_tuple_str_plain_empty_tuple = PyTuple_New( 1 ); |
|
const_str_plain_empty = UNSTREAM_STRING_ASCII( &constant_bin[ 9 ], 5, 1 ); |
|
const_str_plain_empty = UNSTREAM_STRING_ASCII( &constant_bin[ 9 ], 5, 1 ); |
|
PyTuple_SET_ITEM( const_tuple_str_plain_empty_tuple, 0, const_str_plain_empty ); Py_INCREF( const_str_plain_empty ); |
|
PyTuple_SET_ITEM( const_tuple_str_plain_empty_tuple, 0, const_str_plain_empty ); Py_INCREF( const_str_plain_empty ); |
|
const_str_plain_module_var = UNSTREAM_STRING_ASCII( &constant_bin[ 14 ], 10, 1 ); |
|
const_str_plain_module_var = UNSTREAM_STRING_ASCII( &constant_bin[ 14 ], 10, 1 ); |
|
const_str_digest_cdf37c612da9238fac3dab7a1b02e671 = UNSTREAM_STRING_ASCII( &constant_bin[ 24 ], 81, 0 ); |
|
const_str_digest_cdf37c612da9238fac3dab7a1b02e671 = UNSTREAM_STRING_ASCII( &constant_bin[ 24 ], 81, 0 ); |
n |
const_str_digest_30e4724e0d508bc0c811d26a46d4b6cd = UNSTREAM_STRING_ASCII( &constant_bin[ 105 ], 31, 0 ); |
n |
|
|
const_int_pos_50000 = PyLong_FromUnsignedLong( 50000ul ); |
|
const_int_pos_50000 = PyLong_FromUnsignedLong( 50000ul ); |
|
const_tuple_str_digest_5ed1392909ad16e6227b8230f4582352_tuple = PyTuple_New( 1 ); |
|
const_tuple_str_digest_5ed1392909ad16e6227b8230f4582352_tuple = PyTuple_New( 1 ); |
n |
const_str_digest_5ed1392909ad16e6227b8230f4582352 = UNSTREAM_STRING_ASCII( &constant_bin[ 136 ], 3, 0 ); |
n |
const_str_digest_5ed1392909ad16e6227b8230f4582352 = UNSTREAM_STRING_ASCII( &constant_bin[ 105 ], 3, 0 ); |
|
PyTuple_SET_ITEM( const_tuple_str_digest_5ed1392909ad16e6227b8230f4582352_tuple, 0, const_str_digest_5ed1392909ad16e6227b8230f4582352 ); Py_INCREF( const_str_digest_5ed1392909ad16e6227b8230f4582352 ); |
|
PyTuple_SET_ITEM( const_tuple_str_digest_5ed1392909ad16e6227b8230f4582352_tuple, 0, const_str_digest_5ed1392909ad16e6227b8230f4582352 ); Py_INCREF( const_str_digest_5ed1392909ad16e6227b8230f4582352 ); |
n |
const_str_plain_calledRepeatedly = UNSTREAM_STRING_ASCII( &constant_bin[ 105 ], 16, 1 ); |
n |
const_str_plain_calledRepeatedly = UNSTREAM_STRING_ASCII( &constant_bin[ 108 ], 16, 1 ); |
|
const_str_angle_module = UNSTREAM_STRING_ASCII( &constant_bin[ 139 ], 8, 0 ); |
|
const_str_angle_module = UNSTREAM_STRING_ASCII( &constant_bin[ 124 ], 8, 0 ); |
|
const_str_plain_None = UNSTREAM_STRING_ASCII( &constant_bin[ 147 ], 4, 1 ); |
|
const_str_plain_None = UNSTREAM_STRING_ASCII( &constant_bin[ 132 ], 4, 1 ); |
|
const_str_plain_x = UNSTREAM_STRING_ASCII( &constant_bin[ 49 ], 1, 1 ); |
|
const_str_plain_x = UNSTREAM_STRING_ASCII( &constant_bin[ 49 ], 1, 1 ); |
n |
const_str_plain_repeat = UNSTREAM_STRING_ASCII( &constant_bin[ 151 ], 6, 1 ); |
n |
const_str_plain_repeat = UNSTREAM_STRING_ASCII( &constant_bin[ 136 ], 6, 1 ); |
|
const_tuple_none_int_pos_50000_tuple = PyTuple_New( 2 ); |
|
const_tuple_none_int_pos_50000_tuple = PyTuple_New( 2 ); |
|
PyTuple_SET_ITEM( const_tuple_none_int_pos_50000_tuple, 0, Py_None ); Py_INCREF( Py_None ); |
|
PyTuple_SET_ITEM( const_tuple_none_int_pos_50000_tuple, 0, Py_None ); Py_INCREF( Py_None ); |
|
PyTuple_SET_ITEM( const_tuple_none_int_pos_50000_tuple, 1, const_int_pos_50000 ); Py_INCREF( const_int_pos_50000 ); |
|
PyTuple_SET_ITEM( const_tuple_none_int_pos_50000_tuple, 1, const_int_pos_50000 ); Py_INCREF( const_int_pos_50000 ); |
|
|
|
|
|
constants_created = true; |
|
constants_created = true; |
|
#endif |
|
#endif |
|
|
|
|
|
// The module code objects. |
|
// The module code objects. |
|
static PyCodeObject *codeobj_8cbb47534e21aa8c22d35b17d31ddf1a; |
|
static PyCodeObject *codeobj_8cbb47534e21aa8c22d35b17d31ddf1a; |
|
static PyCodeObject *codeobj_38c60160a84ad1b694884ab48627a08f; |
|
static PyCodeObject *codeobj_38c60160a84ad1b694884ab48627a08f; |
n |
static PyCodeObject *codeobj_31f96c13293e42377b28061b8033ed61; |
n |
|
|
/* For use in "MainProgram.c". */ |
|
/* For use in "MainProgram.c". */ |
|
PyCodeObject *codeobj_main = NULL; |
|
PyCodeObject *codeobj_main = NULL; |
|
|
|
|
|
static void createModuleCodeObjects(void) |
|
static void createModuleCodeObjects(void) |
|
{ |
|
{ |
|
module_filename_obj = const_str_digest_cdf37c612da9238fac3dab7a1b02e671; |
|
module_filename_obj = const_str_digest_cdf37c612da9238fac3dab7a1b02e671; |
|
codeobj_8cbb47534e21aa8c22d35b17d31ddf1a = MAKE_CODEOBJ( module_filename_obj, const_str_angle_module, 1, const_tuple_empty, 0, 0, CO_NOFREE ); |
|
codeobj_8cbb47534e21aa8c22d35b17d31ddf1a = MAKE_CODEOBJ( module_filename_obj, const_str_angle_module, 1, const_tuple_empty, 0, 0, CO_NOFREE ); |
|
codeobj_main = codeobj_8cbb47534e21aa8c22d35b17d31ddf1a; |
|
codeobj_main = codeobj_8cbb47534e21aa8c22d35b17d31ddf1a; |
|
codeobj_38c60160a84ad1b694884ab48627a08f = MAKE_CODEOBJ( module_filename_obj, const_str_plain_calledRepeatedly, 23, const_tuple_str_plain_empty_tuple, 0, 0, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE ); |
|
codeobj_38c60160a84ad1b694884ab48627a08f = MAKE_CODEOBJ( module_filename_obj, const_str_plain_calledRepeatedly, 23, const_tuple_str_plain_empty_tuple, 0, 0, CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE ); |
n |
codeobj_31f96c13293e42377b28061b8033ed61 = MAKE_CODEOBJ( module_filename_obj, const_str_plain_empty, 26, const_tuple_empty, 0, 0, CO_GENERATOR | CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE ); |
n |
|
|
} |
|
} |
|
|
|
|
|
// The module function declarations. |
|
// The module function declarations. |
n |
static PyObject *__main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_maker( void ); |
n |
|
|
|
|
|
|
|
|
|
|
static PyObject *MAKE_FUNCTION___main__$$$function_1_calledRepeatedly( ); |
|
static PyObject *MAKE_FUNCTION___main__$$$function_1_calledRepeatedly( ); |
n |
|
n |
|
|
|
|
|
|
static PyObject *MAKE_FUNCTION___main__$$$function_1_calledRepeatedly$$$function_1_empty( ); |
|
|
|
|
|
|
|
|
|
|
|
// The module function definitions. |
|
// The module function definitions. |
|
static PyObject *impl___main__$$$function_1_calledRepeatedly( struct Nuitka_FunctionObject const *self, PyObject **python_pars ) |
|
static PyObject *impl___main__$$$function_1_calledRepeatedly( struct Nuitka_FunctionObject const *self, PyObject **python_pars ) |
|
{ |
|
{ |
|
// Actual function exit with return value, making sure we did not make |
|
// Actual function exit with return value, making sure we did not make |
|
// the error status worse despite non-NULL return. |
|
// the error status worse despite non-NULL return. |
|
CHECK_OBJECT( tmp_return_value ); |
|
CHECK_OBJECT( tmp_return_value ); |
|
assert( had_error || !ERROR_OCCURRED() ); |
|
assert( had_error || !ERROR_OCCURRED() ); |
|
return tmp_return_value; |
|
return tmp_return_value; |
n |
} |
n |
|
|
|
|
|
|
|
|
|
|
static PyObject *impl___main__$$$function_1_calledRepeatedly$$$function_1_empty( struct Nuitka_FunctionObject const *self, PyObject **python_pars ) |
|
|
|
{ |
|
|
|
// Preserve error status for checks |
|
|
|
#ifndef __NUITKA_NO_ASSERT__ |
|
|
|
NUITKA_MAY_BE_UNUSED bool had_error = ERROR_OCCURRED(); |
|
|
|
#endif |
|
|
|
|
|
|
|
// Local variable declarations. |
|
|
|
PyObject *tmp_return_value = NULL; |
|
|
|
|
|
|
|
// Actual function body. |
|
|
|
tmp_return_value = __main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_maker(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
goto function_return_exit; |
|
|
|
|
|
|
|
// Return statement must have exited already. |
|
|
|
NUITKA_CANNOT_GET_HERE( __main__$$$function_1_calledRepeatedly$$$function_1_empty ); |
|
|
|
return NULL; |
|
|
|
|
|
|
|
|
|
|
|
function_return_exit: |
|
|
|
// Function cleanup code if any. |
|
|
|
|
|
|
|
|
|
|
|
// Actual function exit with return value, making sure we did not make |
|
|
|
// the error status worse despite non-NULL return. |
|
|
|
CHECK_OBJECT( tmp_return_value ); |
|
|
|
assert( had_error || !ERROR_OCCURRED() ); |
|
|
|
return tmp_return_value; |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
struct __main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_locals { |
|
|
|
char const *type_description_1; |
|
|
|
PyObject *exception_type; |
|
|
|
PyObject *exception_value; |
|
|
|
PyTracebackObject *exception_tb; |
|
|
|
int exception_lineno; |
|
|
|
}; |
|
|
|
|
|
|
|
static PyObject *__main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_context( struct Nuitka_GeneratorObject *generator, PyObject *yield_return_value ) |
|
|
|
{ |
|
|
|
CHECK_OBJECT( (PyObject *)generator ); |
|
|
|
assert( Nuitka_Generator_Check( (PyObject *)generator ) ); |
|
|
|
|
|
|
|
// Heap access if used. |
|
|
|
struct __main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_locals *generator_heap = (struct __main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_locals *)generator->m_heap_storage; |
|
|
|
|
|
|
|
// Dispatch to yield based on return label index: |
|
|
|
switch(generator->m_yield_return_index) { |
|
|
|
case 1: goto yield_return_1; |
|
|
|
} |
|
|
|
|
|
|
|
// Local variable initialization |
|
|
|
static struct Nuitka_FrameObject *cache_m_frame = NULL; |
|
|
|
generator_heap->type_description_1 = NULL; |
|
|
|
generator_heap->exception_type = NULL; |
|
|
|
generator_heap->exception_value = NULL; |
|
|
|
generator_heap->exception_tb = NULL; |
|
|
|
generator_heap->exception_lineno = 0; |
|
|
|
|
|
|
|
// Actual generator function body. |
|
|
|
MAKE_OR_REUSE_FRAME( cache_m_frame, codeobj_31f96c13293e42377b28061b8033ed61, module___main__, 0 ); |
|
|
|
generator->m_frame = cache_m_frame; |
|
|
|
|
|
|
|
// Mark the frame object as in use, ref count 1 will be up for reuse. |
|
|
|
Py_INCREF( generator->m_frame ); |
|
|
|
assert( Py_REFCNT( generator->m_frame ) == 2 ); // Frame stack |
|
|
|
|
|
|
|
#if PYTHON_VERSION >= 340 |
|
|
|
generator->m_frame->m_frame.f_gen = (PyObject *)generator; |
|
|
|
#endif |
|
|
|
|
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_back ); |
|
|
|
|
|
|
|
generator->m_frame->m_frame.f_back = PyThreadState_GET()->frame; |
|
|
|
Py_INCREF( generator->m_frame->m_frame.f_back ); |
|
|
|
|
|
|
|
PyThreadState_GET()->frame = &generator->m_frame->m_frame; |
|
|
|
Py_INCREF( generator->m_frame ); |
|
|
|
|
|
|
|
Nuitka_Frame_MarkAsExecuting( generator->m_frame ); |
|
|
|
|
|
|
|
#if PYTHON_VERSION >= 300 |
|
|
|
// Accept currently existing exception as the one to publish again when we |
|
|
|
// yield or yield from. |
|
|
|
{ |
|
|
|
PyThreadState *thread_state = PyThreadState_GET(); |
|
|
|
|
|
|
|
#if PYTHON_VERSION < 370 |
|
|
|
generator->m_frame->m_frame.f_exc_type = EXC_TYPE( thread_state ); |
|
|
|
if ( generator->m_frame->m_frame.f_exc_type == Py_None ) generator->m_frame->m_frame.f_exc_type = NULL; |
|
|
|
Py_XINCREF( generator->m_frame->m_frame.f_exc_type ); |
|
|
|
generator->m_frame->m_frame.f_exc_value = EXC_VALUE( thread_state ); |
|
|
|
Py_XINCREF( generator->m_frame->m_frame.f_exc_value ); |
|
|
|
generator->m_frame->m_frame.f_exc_traceback = EXC_TRACEBACK( thread_state ); |
|
|
|
Py_XINCREF( generator->m_frame->m_frame.f_exc_traceback ); |
|
|
|
#else |
|
|
|
generator->m_exc_state.exc_type = EXC_TYPE( thread_state ); |
|
|
|
if ( generator->m_exc_state.exc_type == Py_None ) generator->m_exc_state.exc_type = NULL; |
|
|
|
Py_XINCREF( generator->m_exc_state.exc_type ); |
|
|
|
generator->m_exc_state.exc_value = EXC_VALUE( thread_state ); |
|
|
|
Py_XINCREF( generator->m_exc_state.exc_value ); |
|
|
|
generator->m_exc_state.exc_traceback = EXC_TRACEBACK( thread_state ); |
|
|
|
Py_XINCREF( generator->m_exc_state.exc_traceback ); |
|
|
|
#endif |
|
|
|
} |
|
|
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
// Framed code: |
|
|
|
{ |
|
|
|
PyObject *tmp_expression_name_1; |
|
|
|
NUITKA_MAY_BE_UNUSED PyObject *tmp_yield_result_1; |
|
|
|
tmp_expression_name_1 = const_int_pos_1; |
|
|
|
Py_INCREF( tmp_expression_name_1 ); |
|
|
|
generator->m_yield_return_index = 1; |
|
|
|
return tmp_expression_name_1; |
|
|
|
yield_return_1: |
|
|
|
if ( yield_return_value == NULL ) |
|
|
|
{ |
|
|
|
assert( ERROR_OCCURRED() ); |
|
|
|
|
|
|
|
FETCH_ERROR_OCCURRED( &generator_heap->exception_type, &generator_heap->exception_value, &generator_heap->exception_tb ); |
|
|
|
|
|
|
|
|
|
|
|
generator_heap->exception_lineno = 27; |
|
|
|
|
|
|
|
goto frame_exception_exit_1; |
|
|
|
} |
|
|
|
tmp_yield_result_1 = yield_return_value; |
|
|
|
} |
|
|
|
|
|
|
|
Nuitka_Frame_MarkAsNotExecuting( generator->m_frame ); |
|
|
|
|
|
|
|
#if PYTHON_VERSION >= 370 |
|
|
|
Py_CLEAR( generator->m_exc_state.exc_type ); |
|
|
|
Py_CLEAR( generator->m_exc_state.exc_value ); |
|
|
|
Py_CLEAR( generator->m_exc_state.exc_traceback ); |
|
|
|
#elif PYTHON_VERSION >= 300 |
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_exc_type ); |
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_exc_value ); |
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_exc_traceback ); |
|
|
|
#endif |
|
|
|
|
|
|
|
// Allow re-use of the frame again. |
|
|
|
Py_DECREF( generator->m_frame ); |
|
|
|
goto frame_no_exception_1; |
|
|
|
|
|
|
|
frame_exception_exit_1:; |
|
|
|
|
|
|
|
// If it's not an exit exception, consider and create a traceback for it. |
|
|
|
if ( !EXCEPTION_MATCH_GENERATOR( generator_heap->exception_type ) ) |
|
|
|
{ |
|
|
|
if ( generator_heap->exception_tb == NULL ) |
|
|
|
{ |
|
|
|
generator_heap->exception_tb = MAKE_TRACEBACK( generator->m_frame, generator_heap->exception_lineno ); |
|
|
|
} |
|
|
|
else if ( generator_heap->exception_tb->tb_frame != &generator->m_frame->m_frame ) |
|
|
|
{ |
|
|
|
generator_heap->exception_tb = ADD_TRACEBACK( generator_heap->exception_tb, generator->m_frame, generator_heap->exception_lineno ); |
|
|
|
} |
|
|
|
|
|
|
|
Nuitka_Frame_AttachLocals( |
|
|
|
(struct Nuitka_FrameObject *)generator->m_frame, |
|
|
|
generator_heap->type_description_1 |
|
|
|
); |
|
|
|
|
|
|
|
|
|
|
|
// Release cached frame. |
|
|
|
if ( generator->m_frame == cache_m_frame ) |
|
|
|
{ |
|
|
|
Py_DECREF( generator->m_frame ); |
|
|
|
} |
|
|
|
cache_m_frame = NULL; |
|
|
|
|
|
|
|
assertFrameObject( generator->m_frame ); |
|
|
|
} |
|
|
|
|
|
|
|
#if PYTHON_VERSION >= 370 |
|
|
|
Py_CLEAR( generator->m_exc_state.exc_type ); |
|
|
|
Py_CLEAR( generator->m_exc_state.exc_value ); |
|
|
|
Py_CLEAR( generator->m_exc_state.exc_traceback ); |
|
|
|
#elif PYTHON_VERSION >= 300 |
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_exc_type ); |
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_exc_value ); |
|
|
|
Py_CLEAR( generator->m_frame->m_frame.f_exc_traceback ); |
|
|
|
#endif |
|
|
|
|
|
|
|
Py_DECREF( generator->m_frame ); |
|
|
|
|
|
|
|
// Return the error. |
|
|
|
goto function_exception_exit; |
|
|
|
|
|
|
|
frame_no_exception_1:; |
|
|
|
|
|
|
|
|
|
|
|
return NULL; |
|
|
|
|
|
|
|
function_exception_exit: |
|
|
|
assert( generator_heap->exception_type ); |
|
|
|
RESTORE_ERROR_OCCURRED( generator_heap->exception_type, generator_heap->exception_value, generator_heap->exception_tb ); |
|
|
|
|
|
|
|
return NULL; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
static PyObject *__main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_maker( void ) |
|
|
|
{ |
|
|
|
return Nuitka_Generator_New( |
|
|
|
__main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_context, |
|
|
|
module___main__, |
|
|
|
const_str_plain_empty, |
|
|
|
#if PYTHON_VERSION >= 350 |
|
|
|
const_str_digest_30e4724e0d508bc0c811d26a46d4b6cd, |
|
|
|
#endif |
|
|
|
codeobj_31f96c13293e42377b28061b8033ed61, |
|
|
|
0, |
|
|
|
sizeof(struct __main__$$$function_1_calledRepeatedly$$$function_1_empty$$$genobj_1_empty_locals) |
|
|
|
); |
|
|
|
} |
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
static PyObject *MAKE_FUNCTION___main__$$$function_1_calledRepeatedly( ) |
|
static PyObject *MAKE_FUNCTION___main__$$$function_1_calledRepeatedly( ) |