New submission from Atsuo Ishimoto <ishim...@gembook.org>:

When I use Py_UNICODE_ISSPACE() in my C++ extension, I got following error.

test.obj : error LNK2019: unresolved external symbol
"__declspec(dllimport) unsigned char const * const _Py_ascii_whitespace"
(__imp_?_Py_ascii_whitespace@@3QBEB) referenced in function "struct
_object * __cdecl fff(struct _object *,struct _object *)"
(?fff@@YAPAU_object@@p...@0@Z)

Py_ascii_whitespace defined in unicodeobject.h should be enclosed by
'extern "C" {' block for C++ support.

Tested with Python 2.6.1/VS2008 express.

----------
messages: 79160
nosy: ishimoto
severity: normal
status: open
title: Py_UNICODE_ISSPACE causes linker error
type: compile error
versions: Python 2.6

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue4846>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to