Commit Graph

3602 Commits

Author SHA1 Message Date
Florent Xicluna aa6c1d240f Issue #13575: there is only one class type. 2011-12-12 18:54:29 +01:00
Florent Xicluna 720682efd1 Merge 3.2 2011-12-09 23:42:29 +01:00
Florent Xicluna 5126df602c Remove obsolete py3k comment. 2011-12-09 23:41:21 +01:00
Charles-François Natali 1659b83b1d Followup to a541bda2f5e2: Add a short comment. 2011-12-07 23:17:58 +01:00
Charles-François Natali 7c0b0cc9f9 Issue #11051: Reduce the number of syscalls per import. 2011-12-07 19:16:01 +01:00
Mark Dickinson 47862d4c0e Issue #9530: Fix undefined behaviour due to signed overflow in Python/formatter_unicode.c. 2011-12-01 15:27:04 +00:00
Victor Stinner ee450093a9 PyCodec_IgnoreErrors() avoids the deprecated "u#" format 2011-12-01 02:52:11 +01:00
Antoine Pitrou 39a73a4cfa Issue #7111: Python can now be run without a stdin, stdout or stderr stream.
It was already the case with Python 2.  However, the corresponding
sys module entries are now set to None (instead of an unusable file object).
2011-11-28 19:09:45 +01:00
Antoine Pitrou 11942a58a1 Issue #7111: Python can now be run without a stdin, stdout or stderr stream.
It was already the case with Python 2.  However, the corresponding
sys module entries are now set to None (instead of an unusable file object).
2011-11-28 19:08:36 +01:00
Antoine Pitrou 5604ef3e36 Issue #13444: When stdout has been closed explicitly, we should not attempt to flush it at shutdown and print an error.
This also adds a test for issue #5319, whose resolution introduced the issue.
2011-11-26 22:02:29 +01:00
Antoine Pitrou d7c8fbf89e Issue #13444: When stdout has been closed explicitly, we should not attempt to flush it at shutdown and print an error.
This also adds a test for issue #5319, whose resolution introduced the issue.
2011-11-26 21:59:36 +01:00
Antoine Pitrou 86a36b500a PEP 3155 / issue #13448: Qualified name for classes and functions. 2011-11-25 18:56:07 +01:00
Amaury Forgeot d'Arc 942d5ba125 Merge branch 3.2 2011-11-22 22:02:01 +01:00
Amaury Forgeot d'Arc 5e8f810411 Issue #13436: commit regenerated Python-ast.c 2011-11-22 21:52:30 +01:00
Charles-François Natali 23b0b9252e Issue #13156: _PyGILState_Reinit(): Re-associate the auto thread state with the
TLS key only if the thread that called fork() had an associated auto thread
state (this might not be the case for example for a thread created outside of
Python calling into a subinterpreter).
2011-11-22 19:51:14 +01:00
Charles-François Natali a233df885b Issue #13156: _PyGILState_Reinit(): Re-associate the auto thread state with the
TLS key only if the thread that called fork() had an associated auto thread
state (this might not be the case for example for a thread created outside of
Python calling into a subinterpreter).
2011-11-22 19:49:51 +01:00
Victor Stinner 63ab875cfe Remove "#ifdef Py_UNICODE_WIDE": Python is now always wide 2011-11-22 03:31:20 +01:00
Victor Stinner 9d3b93ba30 Use the new Unicode API
* Replace PyUnicode_FromUnicode(NULL, 0) by PyUnicode_New(0, 0)
 * Replce PyUnicode_FromUnicode(str, len) by PyUnicode_FromWideChar(str, len)
 * Replace Py_UNICODE by wchar_t
 * posix_putenv() uses PyUnicode_FromFormat() to create the string, instead
   of PyUnicode_FromUnicode() + _snwprintf()
2011-11-22 02:27:30 +01:00
Victor Stinner 9e30aa52fd Fix misuse of PyUnicode_GET_SIZE() => PyUnicode_GET_LENGTH()
And PyUnicode_GetSize() => PyUnicode_GetLength()
2011-11-21 02:49:52 +01:00
Victor Stinner 3335447646 Check for PyUnicode_AS_UNICODE() failure 2011-11-21 02:01:41 +01:00
Victor Stinner e251d6d69d print_exception() uses PyUnicode_GetLength() instead of PyUnicode_GetSize() 2011-11-20 19:20:00 +01:00
Antoine Pitrou f34a0cdc6c Issue #10227: Add an allocation cache for a single slice object.
Patch by Stefan Behnel.
2011-11-18 20:14:34 +01:00
Victor Stinner ee587eaa36 Catch PyUnicode_AS_UNICODE() errors in fileutils.c 2011-11-17 00:51:38 +01:00
Victor Stinner 1f7951711c Catch PyUnicode_AS_UNICODE() errors 2011-11-17 00:45:54 +01:00
Antoine Pitrou 8ad982cccf Use PyUnicode_FromFormat() to create the temporary file name.
Also, as in importlib, append the id of an object to make the file name
pseudo-random.
2011-11-15 22:27:32 +01:00
Antoine Pitrou 1d8f3f451c Fix regression under Windows following b75b41237380 (from issue #13392) 2011-11-15 20:40:55 +01:00
Antoine Pitrou 28e401e717 Issue #13392: Writing a pyc file should now be atomic under Windows as well. 2011-11-15 19:15:19 +01:00
Charles-François Natali 0c929d9d39 Issue #13303: Fix bytecode file default permission. 2011-11-10 19:12:29 +01:00
Martin v. Löwis d10759f6ed Make _PyUnicode_FromId return borrowed references.
http://mail.python.org/pipermail/python-dev/2011-November/114347.html
2011-11-07 13:00:05 +01:00
Philip Jenvey 50add04836 quote the type name for improved readability 2011-11-06 16:37:52 -08:00
Antoine Pitrou 5ee9d8a8a2 Issue #13342: input() used to ignore sys.stdin's and sys.stdout's unicode
error handler in interactive mode (when calling into PyOS_Readline()).
2011-11-06 00:38:45 +01:00
Antoine Pitrou 0d776b1ce8 Issue #13342: input() used to ignore sys.stdin's and sys.stdout's unicode
error handler in interactive mode (when calling into PyOS_Readline()).
2011-11-06 00:34:26 +01:00
Amaury Forgeot d'Arc 9028a10144 Issue #13343: Fix a SystemError when a lambda expression uses a global
variable in the default value of a keyword-only argument:
(lambda *, arg=GLOBAL_NAME: None)
2011-11-04 22:29:24 +01:00
Amaury Forgeot d'Arc 97c1bef6a4 Issue #13343: Fix a SystemError when a lambda expression uses a global
variable in the default value of a keyword-only argument:
(lambda *, arg=GLOBAL_NAME: None)
2011-11-04 22:17:45 +01:00
Victor Stinner c06bb7affd Avoid the Py_UNICODE type in codecs.c 2011-11-04 21:36:35 +01:00
Victor Stinner b31f1bcd99 PyCodec_XMLCharRefReplaceError(): Remove unused variable 2011-11-04 21:29:10 +01:00
Martin v. Löwis 8ba79306d1 Fix C89 incompatibility. 2011-11-04 12:26:49 +01:00
Martin v. Löwis b09af03b8a Port error handlers from Py_UNICODE indexing to code point indexing. 2011-11-04 11:16:41 +01:00
Éric Araujo e64052176d Merge follow-up for #11254 and other changes from 3.2 2011-11-03 05:17:11 +01:00
Éric Araujo 5df1108de2 Add signatures to the docstring of functions added to imp by PEP 3147 2011-11-03 03:38:44 +01:00
Antoine Pitrou 8db076cf8a Issue #10363: Deallocate global locks in Py_Finalize(). 2011-10-30 19:13:55 +01:00
Florent Xicluna 4d46c2a722 Remove unused variable. 2011-10-28 15:00:50 +02:00
Nick Coghlan de31b191e5 Issue 1294232: Fix errors in metaclass calculation affecting some cases of metaclass inheritance. Patch by Daniel Urban. 2011-10-23 22:04:16 +10:00
Charles-François Natali e695eec24a Issue #13303: Fix a race condition in the bytecode file creation. 2011-10-31 20:47:31 +01:00
Victor Stinner f4afa43fd4 Issue #13226: Update sys.setdlopenflags() docstring
Refer to os.RTLD_xxx constants instead of ctypes and DLFCN modules.
2011-10-31 11:48:09 +01:00
Martin v. Löwis f45dee998f Port import_module_level to Unicode API. 2011-10-30 23:50:02 +01:00
Antoine Pitrou 6fbbc33440 Issue #10363: Deallocate global locks in Py_Finalize(). 2011-10-30 19:14:46 +01:00
Martin v. Löwis 796ea53937 Port PyImport_ReloadModule to Unicode API. 2011-10-30 09:07:07 +01:00
Florent Xicluna 908ae24b06 Merge 3.2 (linked to issue #1294232) 2011-10-28 15:06:13 +02:00
Antoine Pitrou b528fcf954 Fix test_imp failure under Windows 2011-10-25 00:21:02 +02:00