using RAII to manage GIL -- still fails to handle exceptions correctly
This commit is contained in:
@@ -19,9 +19,10 @@ gen_template_parse_args = Template("""const char* keywords[] = { $kw_list, NULL
|
||||
gen_template_func_body = Template("""$code_decl
|
||||
$code_parse
|
||||
{
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
$code_fcall;
|
||||
Py_END_ALLOW_THREADS
|
||||
{
|
||||
PyAllowThreads allow;
|
||||
$code_fcall;
|
||||
}
|
||||
$code_ret;
|
||||
}
|
||||
""")
|
||||
|
Reference in New Issue
Block a user