I cythonize *.pyx
files manually using
cython -3 -Wextra mymodule.pyx
I use the -Wextra
option to generate additional warnings, useful for cleaning up redundant code pieces. However, many warnings of the form
warning: mymodule.pyx:123:45: local variable 'x' might be referenced before assignment
are printed, which I do not care for. I understand why it is not obvious from the perspective of the compiler, but under no circumstance is it ever possible for x
to not be assigned before referencing, in my particular situation.
I would therefore like to keep using -Wextra
but filter out this type of warning, similar to the -Wno
option of gcc. I have however not been able to track down such a feature.