]> granicus.if.org Git - python/log
python
14 years agoRevert r85801. The test ought to pass without rounding.
Martin v. Löwis [Sat, 23 Oct 2010 19:02:30 +0000 (19:02 +0000)]
Revert r85801. The test ought to pass without rounding.

14 years agoFollow up to #9778: fix regressions on 64-bit Windows builds
Antoine Pitrou [Sat, 23 Oct 2010 17:37:54 +0000 (17:37 +0000)]
Follow up to #9778: fix regressions on 64-bit Windows builds

14 years ago#6518: enable context manager protocol for ossaudiodev types.
Georg Brandl [Sat, 23 Oct 2010 17:31:52 +0000 (17:31 +0000)]
#6518: enable context manager protocol for ossaudiodev types.

14 years agoAlso guard other SOCK_NONBLOCK test
Antoine Pitrou [Sat, 23 Oct 2010 17:05:13 +0000 (17:05 +0000)]
Also guard other SOCK_NONBLOCK test

14 years agoIssue #6011: sysconfig and distutils.sysconfig use the surrogateescape error
Victor Stinner [Sat, 23 Oct 2010 17:02:31 +0000 (17:02 +0000)]
Issue #6011: sysconfig and distutils.sysconfig use the surrogateescape error
handler to parse the Makefile file. Avoid a UnicodeDecodeError if the source
code directory name contains a non-ASCII character and the locale encoding is
ASCII.

14 years agoFix SOCK_CLOEXEC and SOCK_NONBLOCK tests on recent glibcs with old Linux kernels.
Antoine Pitrou [Sat, 23 Oct 2010 17:01:44 +0000 (17:01 +0000)]
Fix SOCK_CLOEXEC and SOCK_NONBLOCK tests on recent glibcs with old Linux kernels.

14 years agofollow up to #9778: define and use an unsigned hash type
Benjamin Peterson [Sat, 23 Oct 2010 16:20:50 +0000 (16:20 +0000)]
follow up to #9778: define and use an unsigned hash type

14 years agoTry to fix test_tarfile on AMD64 debian parallel 3.x
Victor Stinner [Sat, 23 Oct 2010 01:15:30 +0000 (01:15 +0000)]
Try to fix test_tarfile on AMD64 debian parallel 3.x

tarinfo.mtime is an int, whereas getmtime() is a float and it might be
different by something like 3 µs.

14 years agoIssue #6011: getpath: decode VPATH env var from the locale encoding
Victor Stinner [Sat, 23 Oct 2010 00:13:28 +0000 (00:13 +0000)]
Issue #6011: getpath: decode VPATH env var from the locale encoding

Instead of casting it to wchar_t* without conversion. It fixes a bug if Python
is compiled a non-ascii directory, different than the source code directory,
with C locale.

14 years agoRevert r85797 (and r85798): it broke the Windows buildbots because of
Antoine Pitrou [Fri, 22 Oct 2010 21:41:05 +0000 (21:41 +0000)]
Revert r85797 (and r85798): it broke the Windows buildbots because of
test_multiprocessing's misbehaviour.

14 years agoUpdate what's new
Antoine Pitrou [Fri, 22 Oct 2010 19:45:13 +0000 (19:45 +0000)]
Update what's new

14 years agoIssue #9935: Speed up pickling of instances of user-defined classes.
Antoine Pitrou [Fri, 22 Oct 2010 19:43:59 +0000 (19:43 +0000)]
Issue #9935: Speed up pickling of instances of user-defined classes.

14 years agoFor now, remove accept4() code (issue #10115)
Antoine Pitrou [Fri, 22 Oct 2010 18:44:15 +0000 (18:44 +0000)]
For now, remove accept4() code (issue #10115)

14 years agoFix test_ssl on Ubuntu buildbot with patched OpenSSL
Antoine Pitrou [Fri, 22 Oct 2010 18:24:20 +0000 (18:24 +0000)]
Fix test_ssl on Ubuntu buildbot with patched OpenSSL

14 years agoIssue #5639: Add a *server_hostname* argument to `SSLContext.wrap_socket`
Antoine Pitrou [Fri, 22 Oct 2010 18:19:07 +0000 (18:19 +0000)]
Issue #5639: Add a *server_hostname* argument to `SSLContext.wrap_socket`
in order to support the TLS SNI extension.  `HTTPSConnection` and
`urlopen()` also use this argument, so that HTTPS virtual hosts are now
supported.

14 years agoOnly hack cmd.library_dirs when running under Py_ENABLE_SHARED. Tested both
Barry Warsaw [Fri, 22 Oct 2010 17:17:51 +0000 (17:17 +0000)]
Only hack cmd.library_dirs when running under Py_ENABLE_SHARED.  Tested both
with and without --enable-shared on Ubuntu 10.10.  Hopefully this finally
solves bug 10126.  Will check 3.1 next.

14 years agoRefactor interesting use of try-finally.
Georg Brandl [Fri, 22 Oct 2010 06:35:59 +0000 (06:35 +0000)]
Refactor interesting use of try-finally.

14 years agoMake top_level attribute a set instead of a dict with None values.
Georg Brandl [Fri, 22 Oct 2010 06:29:21 +0000 (06:29 +0000)]
Make top_level attribute a set instead of a dict with None values.

14 years ago#10166: rewrite self-recursion to iteration in pstats.Stats.add(). Also add a unitte...
Georg Brandl [Fri, 22 Oct 2010 06:28:01 +0000 (06:28 +0000)]
#10166: rewrite self-recursion to iteration in pstats.Stats.add().  Also add a unittest and a stats test file.

14 years agoApply fix from r85784 on py3k too.
Éric Araujo [Thu, 21 Oct 2010 23:02:07 +0000 (23:02 +0000)]
Apply fix from r85784 on py3k too.

Fixes bug #10126 for Python 3.2 by using $RUNSHARED to find the
directory to the shared library.  test_distutils now passes when
Python was built with --enable-shared (Barry didn’t have the error
but I did).

14 years agoFixed a typo
Alexander Belopolsky [Thu, 21 Oct 2010 22:29:36 +0000 (22:29 +0000)]
Fixed a typo

14 years agoIssue #7061: Fixed section title
Alexander Belopolsky [Thu, 21 Oct 2010 18:15:39 +0000 (18:15 +0000)]
Issue #7061: Fixed section title

14 years agoAdd .hgeol file for the Mercurial EOL extension.
Georg Brandl [Thu, 21 Oct 2010 15:44:51 +0000 (15:44 +0000)]
Add .hgeol file for the Mercurial EOL extension.

14 years agoFix r85774 editor fail. Had a dangling try and incorrect indent.
Brian Curtin [Thu, 21 Oct 2010 14:45:01 +0000 (14:45 +0000)]
Fix r85774 editor fail. Had a dangling try and incorrect indent.

14 years agoFix #10162: Add try/except around _winreg.OpenKey for keys that are
Brian Curtin [Thu, 21 Oct 2010 14:11:48 +0000 (14:11 +0000)]
Fix #10162: Add try/except around _winreg.OpenKey for keys that are
unreadable by all users, e.g., Flash, Silverlight, and Java keys were
causing errors.

We don't currently have a way to grant/deny permissions for a key
via winreg so there are no tests for this.

14 years ago#4829: better error message for invalid file mode
Georg Brandl [Thu, 21 Oct 2010 13:45:52 +0000 (13:45 +0000)]
#4829: better error message for invalid file mode

14 years agoIssue #10089: Add support for arbitrary -X options on the command-line.
Antoine Pitrou [Thu, 21 Oct 2010 13:42:28 +0000 (13:42 +0000)]
Issue #10089: Add support for arbitrary -X options on the command-line.
They can be retrieved through a new attribute `sys._xoptions`.

14 years ago#1203650: allow larger list of files in windows makefile for freeze.
Georg Brandl [Thu, 21 Oct 2010 13:34:51 +0000 (13:34 +0000)]
#1203650: allow larger list of files in windows makefile for freeze.

14 years ago#3077: fix h2py substitution of character literals.
Georg Brandl [Thu, 21 Oct 2010 13:29:10 +0000 (13:29 +0000)]
#3077: fix h2py substitution of character literals.

14 years agoFix missing import.
Georg Brandl [Thu, 21 Oct 2010 13:01:23 +0000 (13:01 +0000)]
Fix missing import.

14 years ago#9919: fix off-by-one error in lineno command in Misc/gdbinit; also add newline to...
Georg Brandl [Thu, 21 Oct 2010 12:59:14 +0000 (12:59 +0000)]
#9919: fix off-by-one error in lineno command in Misc/gdbinit; also add newline to its output.

14 years ago#9095, #8912, #8999: add support in patchcheck for Mercurial checkouts, C file reinde...
Georg Brandl [Thu, 21 Oct 2010 12:49:28 +0000 (12:49 +0000)]
#9095, #8912, #8999: add support in patchcheck for Mercurial checkouts, C file reindenting, and docs whitespace fixing.

14 years ago#10159: sort completion matches before comparing to dir() result.
Georg Brandl [Thu, 21 Oct 2010 07:40:03 +0000 (07:40 +0000)]
#10159: sort completion matches before comparing to dir() result.

14 years agoIssue #4388: On Mac OS X, decode command line arguments from UTF-8, instead of
Victor Stinner [Wed, 20 Oct 2010 22:58:25 +0000 (22:58 +0000)]
Issue #4388: On Mac OS X, decode command line arguments from UTF-8, instead of
the locale encoding. If the LANG (and LC_ALL and LC_CTYPE) environment variable
is not set, the locale encoding is ISO-8859-1, whereas most programs (including
Python) expect UTF-8. Python already uses UTF-8 for the filesystem encoding and
to encode command line arguments on this OS.

14 years agoMove non-ascii test from test_run_code() to a new function: test_non_ascii()
Victor Stinner [Wed, 20 Oct 2010 21:56:55 +0000 (21:56 +0000)]
Move non-ascii test from test_run_code() to a new function: test_non_ascii()

14 years agoMove test_undecodable_code() from test_sys to test_cmd_line
Victor Stinner [Wed, 20 Oct 2010 21:52:33 +0000 (21:52 +0000)]
Move test_undecodable_code() from test_sys to test_cmd_line

14 years agotest_zipimport_support: use ascii() on bytes output to avoid BytesWarning
Victor Stinner [Wed, 20 Oct 2010 21:48:35 +0000 (21:48 +0000)]
test_zipimport_support: use ascii() on bytes output to avoid BytesWarning

The test failed with python -bb.

14 years agofix uninitialized struct member #10152
Benjamin Peterson [Wed, 20 Oct 2010 21:25:23 +0000 (21:25 +0000)]
fix uninitialized struct member #10152

14 years agologging: Improved StreamHandler documentation.
Vinay Sajip [Wed, 20 Oct 2010 20:34:09 +0000 (20:34 +0000)]
logging: Improved StreamHandler documentation.

14 years agologging: Made StreamHandler terminator configurable.
Vinay Sajip [Wed, 20 Oct 2010 20:05:38 +0000 (20:05 +0000)]
logging: Made StreamHandler terminator configurable.

14 years agoFix for issue #7473.
Ronald Oussoren [Wed, 20 Oct 2010 13:10:12 +0000 (13:10 +0000)]
Fix for issue #7473.

Without this patch you'll get link errors in some extensions
(in particular the _curses_panel) one when you try to build
a 3-way universal framework when you previously installed a
2-way universal framework using the python.org installer.

14 years agoDon't lie about the supported architectures in the OSX installer
Ronald Oussoren [Wed, 20 Oct 2010 12:56:56 +0000 (12:56 +0000)]
Don't lie about the supported architectures in the OSX installer

Without this patch the i386/x86_64 installer for OSX 10.6
lies in the ReadMe file and the "Important Information" screen
of the installer (that is, the installer claims it supports
the i386 and ppc architectures insetead of the ones it really
supports)

14 years agologging: clarified Filter documentation.
Vinay Sajip [Wed, 20 Oct 2010 11:40:02 +0000 (11:40 +0000)]
logging: clarified Filter documentation.

14 years agoFix r85728: use "" to mean the system default locale, which should work on more systems.
Georg Brandl [Wed, 20 Oct 2010 06:50:19 +0000 (06:50 +0000)]
Fix r85728: use "" to mean the system default locale, which should work on more systems.

14 years agoCorrect signature of BytesGenerator in docs.
R. David Murray [Tue, 19 Oct 2010 23:05:35 +0000 (23:05 +0000)]
Correct signature of BytesGenerator in docs.

14 years agologging: Documented usage of callables as filters.
Vinay Sajip [Tue, 19 Oct 2010 21:13:49 +0000 (21:13 +0000)]
logging: Documented usage of callables as filters.

14 years agoIssue #7061: Fixed some of the issues in turtle module documentation
Alexander Belopolsky [Tue, 19 Oct 2010 21:07:52 +0000 (21:07 +0000)]
Issue #7061: Fixed some of the issues in turtle module documentation
reported by Terry J. Reedy.

14 years agoBe consistent in the spelling of thread-safe(ty).
Georg Brandl [Tue, 19 Oct 2010 21:07:16 +0000 (21:07 +0000)]
Be consistent in the spelling of thread-safe(ty).

14 years agologging: Allowed filters to be just callables.
Vinay Sajip [Tue, 19 Oct 2010 20:53:01 +0000 (20:53 +0000)]
logging: Allowed filters to be just callables.

14 years agologging: Added tests for _logRecordClass changes.
Vinay Sajip [Tue, 19 Oct 2010 20:44:14 +0000 (20:44 +0000)]
logging: Added tests for _logRecordClass changes.

14 years ago#10092: Properly reset locale in Locale*Calendar classes. The context manager was...
Georg Brandl [Tue, 19 Oct 2010 18:54:25 +0000 (18:54 +0000)]
#10092: Properly reset locale in Locale*Calendar classes.  The context manager was buggy because setlocale() returns the *new* locale, not the old.  Also add a test for this.

14 years agoFixed the docstring for calendar.isleap() function.
Alexander Belopolsky [Tue, 19 Oct 2010 17:43:50 +0000 (17:43 +0000)]
Fixed the docstring for calendar.isleap() function.
Thanks Boštjan Mejak for the patch.

14 years agologging: Added _logRecordClass, getLogRecordClass, setLogRecordClass to increase...
Vinay Sajip [Tue, 19 Oct 2010 15:26:24 +0000 (15:26 +0000)]
logging: Added _logRecordClass, getLogRecordClass, setLogRecordClass to increase flexibility of LogRecord creation.

14 years agoFix Issue10140 - Tools/scripts/pathfix.py: add option to preserve timestamps
Senthil Kumaran [Tue, 19 Oct 2010 04:39:35 +0000 (04:39 +0000)]
Fix Issue10140 - Tools/scripts/pathfix.py: add option to preserve timestamps

14 years agoinitfsencoding(): get_codeset() failure is now a fatal error
Victor Stinner [Tue, 19 Oct 2010 00:05:51 +0000 (00:05 +0000)]
initfsencoding(): get_codeset() failure is now a fatal error

Don't fallback to utf-8 anymore to avoid mojibake. I never got any error from
his function.

14 years agozipimport: remove arbitrary length limit from message formats
Victor Stinner [Mon, 18 Oct 2010 22:45:54 +0000 (22:45 +0000)]
zipimport: remove arbitrary length limit from message formats

PyErr_Format() and PyUnicode_FromFormat() are able to allocate the right buffer
size and to catch memory allocation failures.

14 years agozipimport: document archive encoding; fix indentation
Victor Stinner [Mon, 18 Oct 2010 22:34:46 +0000 (22:34 +0000)]
zipimport: document archive encoding; fix indentation

14 years agoRevert r85699 and r85701 (zipimport): fullname is a module name, not a path
Victor Stinner [Mon, 18 Oct 2010 21:44:33 +0000 (21:44 +0000)]
Revert r85699 and r85701 (zipimport): fullname is a module name, not a path

UTF-8 is just fine for module names.

14 years agozipimport: fix "can't find module ..." error message
Victor Stinner [Mon, 18 Oct 2010 21:21:02 +0000 (21:21 +0000)]
zipimport: fix "can't find module ..." error message

I cannot use %U: fullname is a bytes object, not an unicode object. %A format
cannot be used, it adds 'b' (bytes) prefix. So create cant_find_module()
function to decode the filename and raise the error message.

14 years agoPyUnicode_FromFormatV(): Fix %A format
Victor Stinner [Mon, 18 Oct 2010 20:59:24 +0000 (20:59 +0000)]
PyUnicode_FromFormatV(): Fix %A format

It was not completly implemented. Add a test.

14 years agozipimport: find_module(), is_package() and get_source() supports surrogates
Victor Stinner [Mon, 18 Oct 2010 20:44:08 +0000 (20:44 +0000)]
zipimport: find_module(), is_package() and get_source() supports surrogates

Use PyUnicode_FSConverter to support surrogates in the full name.

14 years agozipimport: pass path size to make_filename()
Victor Stinner [Mon, 18 Oct 2010 20:40:59 +0000 (20:40 +0000)]
zipimport: pass path size to make_filename()

Don't hardcode path size in make_filename().

14 years agoOne more change for issue 9807, by Matthias Klose.
Barry Warsaw [Mon, 18 Oct 2010 17:09:07 +0000 (17:09 +0000)]
One more change for issue 9807, by Matthias Klose.

This adds $ABIFLAGS to the static library, since it should match the shared
library name.  Also, include the abiflags in python-config --libs.

14 years agoReverted inadvertent change that slipped into r85695
Alexander Belopolsky [Mon, 18 Oct 2010 15:11:33 +0000 (15:11 +0000)]
Reverted inadvertent change that slipped into r85695

14 years agoIssue #10117: Tools/scripts/reindent.py now accepts source files that
Alexander Belopolsky [Mon, 18 Oct 2010 14:43:38 +0000 (14:43 +0000)]
Issue #10117: Tools/scripts/reindent.py now accepts source files that
use encoding other than ASCII or UTF-8.  Source encoding is preserved
when reindented code is written to a file.

14 years agoFix hash function type.
Georg Brandl [Mon, 18 Oct 2010 12:24:53 +0000 (12:24 +0000)]
Fix hash function type.

14 years agoget_code_from_data() uses the filesystem encoding to encode the module path,
Victor Stinner [Mon, 18 Oct 2010 12:15:34 +0000 (12:15 +0000)]
get_code_from_data() uses the filesystem encoding to encode the module path,
instead of utf-8.

14 years agozipimport: read_directory() uses cp437 or utf-8 (in strict mode), depending on
Victor Stinner [Mon, 18 Oct 2010 12:13:46 +0000 (12:13 +0000)]
zipimport: read_directory() uses cp437 or utf-8 (in strict mode), depending on
the unicode flag, to decode the filename, instead of the filesystem encoding.
Use the same choice than the zipfile module.

14 years agoIssue #5117: Case normalization was needed on ntpath.relpath(). And
Hirokazu Yamamoto [Mon, 18 Oct 2010 12:13:18 +0000 (12:13 +0000)]
Issue #5117: Case normalization was needed on ntpath.relpath(). And
fixed root directory issue on posixpath.relpath(). (Ported working fixes
from ntpath)

14 years agozipimport: get_module_code() returns modpath as a Unicode object
Victor Stinner [Mon, 18 Oct 2010 12:09:02 +0000 (12:09 +0000)]
zipimport: get_module_code() returns modpath as a Unicode object

... instead of a char*. Encode the module path to the fileystem encoding
(for PyImport_ExecCodeModuleEx) instead of utf-8.

14 years agozipimporter_load_module() doesn't destroy mod on error
Victor Stinner [Mon, 18 Oct 2010 12:03:25 +0000 (12:03 +0000)]
zipimporter_load_module() doesn't destroy mod on error

PyImport_AddModule() returns a borrowed reference. Don't display "import ... #
loaded from Zip ..." on error.

14 years agozipimport: encode the prefix to the fileystem encoding
Victor Stinner [Mon, 18 Oct 2010 11:44:21 +0000 (11:44 +0000)]
zipimport: encode the prefix to the fileystem encoding

14 years agozipimport, get_module_code(): avoid useless _PyUnicode_AsString()
Victor Stinner [Mon, 18 Oct 2010 11:40:40 +0000 (11:40 +0000)]
zipimport, get_module_code(): avoid useless _PyUnicode_AsString()

14 years agozipimport: fix indentation
Victor Stinner [Mon, 18 Oct 2010 11:39:05 +0000 (11:39 +0000)]
zipimport: fix indentation

14 years agoRemove more unneeded casts to hashfunc.
Georg Brandl [Mon, 18 Oct 2010 07:35:09 +0000 (07:35 +0000)]
Remove more unneeded casts to hashfunc.

14 years agoRemove unneeded casts to hashfunc.
Georg Brandl [Mon, 18 Oct 2010 07:32:48 +0000 (07:32 +0000)]
Remove unneeded casts to hashfunc.

14 years agoFix type of hash function.
Georg Brandl [Mon, 18 Oct 2010 07:30:06 +0000 (07:30 +0000)]
Fix type of hash function.

14 years agoFix compiler warning about unused static function.
Georg Brandl [Mon, 18 Oct 2010 07:27:55 +0000 (07:27 +0000)]
Fix compiler warning about unused static function.

14 years agoFix compiler warnings about formatting pid_t as an int, by always casting to long.
Georg Brandl [Mon, 18 Oct 2010 05:06:18 +0000 (05:06 +0000)]
Fix compiler warnings about formatting pid_t as an int, by always casting to long.

14 years ago#678250: Make mmap flush a noop on ACCESS_READ and ACCESS_COPY.
R. David Murray [Mon, 18 Oct 2010 01:14:06 +0000 (01:14 +0000)]
#678250: Make mmap flush a noop on ACCESS_READ and ACCESS_COPY.

Patch by Sébastien Sablé.  This solves a test_mmap failure on AIX.

14 years ago#4499: silence compiler warning on AIX.
R. David Murray [Mon, 18 Oct 2010 00:15:31 +0000 (00:15 +0000)]
#4499: silence compiler warning on AIX.

Patch from ActiveState.

14 years agoTighten up 'byte string' wording in base64 docs.
R. David Murray [Sun, 17 Oct 2010 23:12:16 +0000 (23:12 +0000)]
Tighten up 'byte string' wording in base64 docs.

14 years ago#1343: Add short_empty_elements option to XMLGenerator.
R. David Murray [Sun, 17 Oct 2010 22:46:45 +0000 (22:46 +0000)]
#1343: Add short_empty_elements option to XMLGenerator.

Patch and tests by Neil Muller.

14 years agoNote the resolution of issue 9778.
Skip Montanaro [Sun, 17 Oct 2010 22:22:24 +0000 (22:22 +0000)]
Note the resolution of issue 9778.

14 years ago-1 is reserved for errors
Benjamin Peterson [Sun, 17 Oct 2010 21:27:01 +0000 (21:27 +0000)]
-1 is reserved for errors

14 years agofix prototype
Benjamin Peterson [Sun, 17 Oct 2010 21:20:58 +0000 (21:20 +0000)]
fix prototype

14 years agofix strict aliasing warnings
Benjamin Peterson [Sun, 17 Oct 2010 21:12:18 +0000 (21:12 +0000)]
fix strict aliasing warnings

14 years agomake hashes always the size of pointers; introduce Py_hash_t #9778
Benjamin Peterson [Sun, 17 Oct 2010 20:54:53 +0000 (20:54 +0000)]
make hashes always the size of pointers; introduce Py_hash_t #9778

14 years agotest_httpservers: Python CGI scripts have to be encoded to utf-8
Victor Stinner [Sun, 17 Oct 2010 20:17:41 +0000 (20:17 +0000)]
test_httpservers: Python CGI scripts have to be encoded to utf-8

And not the locale encoding. With this commit, the test finally pass on Windows
with a non-ascii path :-)

14 years agotest_httpservers: Fix skip test check, the python executable path have to be
Victor Stinner [Sun, 17 Oct 2010 20:13:36 +0000 (20:13 +0000)]
test_httpservers: Fix skip test check, the python executable path have to be
encodable to utf-8, not to the file1 encoding.

14 years agouse helper hash unimplemented function
Benjamin Peterson [Sun, 17 Oct 2010 20:13:05 +0000 (20:13 +0000)]
use helper hash unimplemented function

14 years agoFix T_BOOL bug of issue 8845.
Martin v. Löwis [Sun, 17 Oct 2010 19:48:29 +0000 (19:48 +0000)]
Fix T_BOOL bug of issue 8845.

14 years agotest_httpservers: skip CGI tests if Python executable path is not encodable
Victor Stinner [Sun, 17 Oct 2010 19:46:36 +0000 (19:46 +0000)]
test_httpservers: skip CGI tests if Python executable path is not encodable

14 years agoRemove the external non-python.org hyperlink and point people to
Gregory P. Smith [Sun, 17 Oct 2010 19:40:59 +0000 (19:40 +0000)]
Remove the external non-python.org hyperlink and point people to
Tools/gdb/libpython.py.

14 years agoDrop OPT:Olimit, as it confuses SunPRO (and other compilers).
Martin v. Löwis [Sun, 17 Oct 2010 19:36:54 +0000 (19:36 +0000)]
Drop OPT:Olimit, as it confuses SunPRO (and other compilers).

14 years agolibpython: implementation of os.fsencode() with surrogateescape error handler
Victor Stinner [Sun, 17 Oct 2010 19:35:30 +0000 (19:35 +0000)]
libpython: implementation of os.fsencode() with surrogateescape error handler

14 years agorun_file(): encode the filename with PyUnicode_EncodeFSDefault() instead of
Victor Stinner [Sun, 17 Oct 2010 19:34:51 +0000 (19:34 +0000)]
run_file(): encode the filename with PyUnicode_EncodeFSDefault() instead of
PyUnicode_AsUTF8String()

14 years agocompiler_error(): use PyUnicode_DecodeFSDefault() to decode the filename,
Victor Stinner [Sun, 17 Oct 2010 19:16:33 +0000 (19:16 +0000)]
compiler_error(): use PyUnicode_DecodeFSDefault() to decode the filename,
instead of utf-8 in strict mode.

14 years agoPyErr_SyntaxLocationEx() uses PyUnicode_DecodeFSDefault(), instead of
Victor Stinner [Sun, 17 Oct 2010 19:03:16 +0000 (19:03 +0000)]
PyErr_SyntaxLocationEx() uses PyUnicode_DecodeFSDefault(), instead of
PyUnicode_FromString(), to decode the filename.

14 years agoThe py_decref macro was incorrect and unnecessary.
Gregory P. Smith [Sun, 17 Oct 2010 18:59:56 +0000 (18:59 +0000)]
The py_decref macro was incorrect and unnecessary.