#cython: language_level=3
def foo():
class A:
pass
class B(A):
def __init__(self):
super().__init__()
return 42
foo()
cython --embed out.pyx
cl.exe /nologo /Ox /MD /W3 /GS- /Zi -I"c:\Program Files\Python37\include" /Tcout.c /link /OUT:"out.exe" /SUBSYSTEM:CONSOLE /MACHINE:X64 /LIBPATH:"c:\Program Files\Python37\libs"
这在使用python 3.7.2和cython 0.29.7的计算机上的return语句上崩溃。奇怪的是,当我删除devenv /debugexe out.exe
调用时,它运行正常。