New submission from John Nelson <j...@jnelson.ca>:
The symbol "PyStructSequence_UnnnamedField" is not *explicitly* marked for export, causing it to be omitted from python3x.dll on Windows -- and thus unavailable to Windows extension modules. Attempting to use this symbol then fails at link time: test.obj : error LNK2001: unresolved external symbol PyStructSequence_UnnamedField build\lib.win-amd64-3.7\test.cp39-win_amd64.pyd : fatal error LNK1120: 1 unresolved externals The fact that the symbol is missing can also be demonstrated via ctypes: import ctypes from pathlib import Path import sys python_dll = ctypes.CDLL(str(Path(sys.executable).parent / 'python3.dll')) # These don't raise at all python_dll.PyTuple_Type python_dll.PyStructSequence_New # Raises AttributeError python_dll.PyStructSequence_UnnamedField ---------- components: Interpreter Core, Windows messages: 394226 nosy: johnboy2, paul.moore, steve.dower, tim.golden, zach.ware priority: normal severity: normal status: open title: PyStructSequence_UnnamedField unavailable on Windows type: behavior versions: Python 3.7, Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue44220> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com