[issue23104] [Windows x86-64] Incorrect function call
Андрей Парамонов
report at bugs.python.org
Tue Dec 23 12:33:43 CET 2014
New submission from Андрей Парамонов:
To reproduce:
0) Compile attached testlib.c
1) Run the following code:
from __future__ import print_function
from __future__ import unicode_literals
from ctypes import *
testlib = windll.LoadLibrary('testlib')
testfun = testlib.test
class objid(Structure):
_fields_ = [('bytes', c_ubyte*16)]
print('Calling...')
testfun(objid(), c_wchar_p('test'))
print('Done.')
---
It gives different output for different versions of Python and processor architectures:
>c:\python27\python test.py
Calling...
test
Done.
>c:\python34\python test.py
Calling...
test
Done.
>c:\python27-64\python test.py
Calling...
test
Done.
>c:\python34-64\python test.py
Calling...
Done.
It appears that Python 3.4 on Windows x86-64 generates incorrect function call code.
----------
components: ctypes
files: testlib.c
messages: 233042
nosy: Андрей.Парамонов
priority: normal
severity: normal
status: open
title: [Windows x86-64] Incorrect function call
versions: Python 3.4
Added file: http://bugs.python.org/file37534/testlib.c
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue23104>
_______________________________________
More information about the Python-bugs-list
mailing list