[issue37887] some leak in the compiler_assert function

2019-08-20 Thread hai shi
hai shi added the comment: Ok, got it. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

[issue37887] some leak in the compiler_assert function

2019-08-19 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your patch hai shi. But note that assertion_error is a static variable. It is initialized only once. Your change makes it holding a borrowed reference after first call of compiler_assert(). This does not look reliable. In any case assertion_e

[issue37887] some leak in the compiler_assert function

2019-08-19 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Hi hai shi, As you can see in other pars of the code base objects returned from PyUnicode_InternFromString that have static storage class do not need to be deallocated in case there is a failure, so this is not considered a leak as there will be only

[issue37887] some leak in the compiler_assert function

2019-08-19 Thread hai shi
New submission from hai shi : Some reference leak in compiler_assert function, due to not using Py_DECREF(assertion_error) before return. And having a question about code order in compiler_assert function. -- components: Interpreter Core files: compiler_assert.patch keywords: patch m