[Python-Dev] Is Py_WIN_WIDE_FILENAMES still alive? (original) (raw)
Mark Hammond mhammond at skippinet.com.au
Mon Apr 28 06:41:18 CEST 2008
- Previous message: [Python-Dev] Is Py_WIN_WIDE_FILENAMES still alive?
- Next message: [Python-Dev] Is Py_WIN_WIDE_FILENAMES still alive?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello. I noticed when I removes following line in trunk/PC/pyconfig.h
#define PyWINWIDEFILENAMES fileio.c and posixmodule.c (and maybe more) cannot be compiled on Windows. When PyWINWIDEFILENAMES is not defined, how should python behave? - call posix functions like open(2) - call ANSI Win32 APIs like MoveFileA Or maybe this macro is not used anymore?
I believe the macro should be removed, as Python currently assumes Unicode APIs are available in a number of places. This consistent with the versions of Windows Python currently supports. It is possible that patches would be accepted which enable Python to be built without this functionality - in which case the next-best behavior would probably be to convert Unicode to MBCS encoded strings and call the *A versions of the API. Looking at the history for posixmodule.c etc will offer some clues as to how this could best be done.
Cheers,
Mark
- Previous message: [Python-Dev] Is Py_WIN_WIDE_FILENAMES still alive?
- Next message: [Python-Dev] Is Py_WIN_WIDE_FILENAMES still alive?
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]