Commit Graph

519 Commits

Author SHA1 Message Date
Antoine Pitrou edc601855d Remove outdated statement 2012-06-23 14:19:58 +02:00
Benjamin Peterson 3a37b8393c merge 3.2 2012-06-01 23:57:50 -07:00
Benjamin Peterson 8e8fbeae27 don't leak if the __class__ closure is set 2012-06-01 23:57:36 -07:00
Brett Cannon fd0741555b Issue #2377: Make importlib the implementation of __import__().
importlib._bootstrap is now frozen into Python/importlib.h and stored
as _frozen_importlib in sys.modules. Py_Initialize() loads the frozen
code along with sys and imp and then uses _frozen_importlib._install()
to set builtins.__import__() w/ _frozen_importlib.__import__().
2012-04-14 14:10:13 -04:00
Kristján Valur Jónsson 31668b8f7a Issue #14288: Serialization support for builtin iterators. 2012-04-03 10:49:41 +00:00
Benjamin Peterson 0010256de4 fold into one if statement 2012-01-11 21:00:16 -05:00
Benjamin Peterson a12d5c62f7 fix formatting 2012-01-03 16:47:22 -06:00
Georg Brandl bc3b682923 Closes #13761: add a "flush" keyword argument to print(). 2012-01-13 19:41:25 +01:00
Benjamin Peterson 0ab2a26865 merge 3.2 2012-01-11 21:00:48 -05:00
Benjamin Peterson 332503db07 merge 3.2 2012-01-03 16:48:14 -06:00
Victor Stinner 63ab875cfe Remove "#ifdef Py_UNICODE_WIDE": Python is now always wide 2011-11-22 03:31:20 +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
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
Florent Xicluna 908ae24b06 Merge 3.2 (linked to issue #1294232) 2011-10-28 15:06:13 +02:00
Nick Coghlan 9715d26305 Merge issue 1294232 patch from 3.2 2011-10-23 22:36:42 +10:00
Martin v. Löwis bd928fef42 Rename _Py_identifier to _Py_IDENTIFIER. 2011-10-14 10:20:37 +02:00
Martin v. Löwis 1ee1b6fe0d Use identifier API for PyObject_GetAttrString. 2011-10-10 18:11:30 +02:00
Martin v. Löwis afe55bba33 Add API for static strings, primarily good for identifiers.
Thanks to Konrad Schöbel and Jasper Schulz for helping with the mass-editing.
2011-10-09 10:38:36 +02:00
Martin v. Löwis d63a3b8beb Implement PEP 393. 2011-09-28 07:41:54 +02:00
Benjamin Peterson ea281a54f3 include header with PyAST_Validate 2011-08-12 23:10:50 -05:00
Benjamin Peterson 832bfe2ebd add a AST validator (closes #12575) 2011-08-09 16:15:04 -05:00
Benjamin Peterson 405f32c14c plug refleak 2011-07-29 22:43:45 -05:00
Benjamin Peterson 4f921c2e06 bytes -> bytearray 2011-07-29 14:24:29 -05:00
Benjamin Peterson ce071ca4e7 bytes should be verboten in sum() (fixes #12654) 2011-07-29 14:23:47 -05:00
Victor Stinner 99b9538636 Issue #9642: Uniformize the tests on the availability of the mbcs codec
Add a new HAVE_MBCS define.
2011-07-04 14:23:54 +02:00
Victor Stinner d64e8a75e5 Issue #9642: Fix filesystem encoding initialization: use the ANSI code page on
Windows if the mbcs codec is not available, and fail with a fatal error if we
cannot get the locale encoding (if nl_langinfo(CODESET) is not available)
instead of using UTF-8.
2011-07-04 13:48:30 +02:00
Alexander Belopolsky 0df80926c9 Removed 'or long integer' from bin, oct, and hex docstrings. 2011-04-07 00:16:22 -04:00
Alexander Belopolsky 12338ab10b Removed 'or long integer' from bin, oct, and hex docstrings. 2011-04-07 00:15:33 -04:00
Victor Stinner fe93faf98c Issue #3080: Add PyImport_ImportModuleLevelObject() function
Use it for the builtin __import__ function.
2011-03-14 15:54:52 -04:00
Victor Stinner f3fd733f92 Remove useless argument of _PyUnicode_AsDefaultEncodedString() 2011-03-02 01:03:11 +00:00
Victor Stinner 02bfdb3f79 Merged revisions 88530 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r88530 | victor.stinner | 2011-02-23 13:07:37 +0100 (mer., 23 févr. 2011) | 4 lines

  Issue #11272: Fix input() and sys.stdin for Windows newline

  On Windows, input() strips '\r' (and not only '\n'), and sys.stdin uses
  universal newline (replace '\r\n' by '\n').
........
2011-02-23 12:10:23 +00:00
Victor Stinner c0f1a1afae Issue #11272: Fix input() and sys.stdin for Windows newline
On Windows, input() strips '\r' (and not only '\n'), and sys.stdin uses
universal newline (replace '\r\n' by '\n').
2011-02-23 12:07:37 +00:00
Brett Cannon b94767ff44 Issue #8914: fix various warnings from the Clang static analyzer v254. 2011-02-22 20:15:44 +00:00
Georg Brandl 8334fd9285 Add an "optimize" parameter to compile() to control the optimization level, and provide an interface to it in py_compile, compileall and PyZipFile. 2010-12-04 10:26:46 +00:00
Martin v. Löwis 4d0d471a80 Merge branches/pep-0384. 2010-12-03 20:14:31 +00:00
Georg Brandl e5b99f0fb3 Remove redundant includes of headers that are already included by Python.h. 2010-11-30 09:41:01 +00:00
Antoine Pitrou e71362d3de Issue #10518: Bring back the callable() builtin.
Approved by Guido (BDFL) and Georg (RM).
2010-11-27 22:00:11 +00:00
Benjamin Peterson 8f67d0893f make hashes always the size of pointers; introduce Py_hash_t #9778 2010-10-17 20:54:53 +00:00
Victor Stinner 4c7c8c3023 Issue #9713, #10114: Parser functions (eg. PyParser_ASTFromFile) expects
filenames encoded to the filesystem encoding with surrogateescape error handler
(to support undecodable bytes), instead of UTF-8 in strict mode.
2010-10-16 13:14:10 +00:00
Brett Cannon 5305a998d5 Since __import__ is not designed for general use, have its docstring point
people towards importlib.import_module().

Closes issue #7397.
2010-09-27 21:08:38 +00:00
Victor Stinner 5b519e0201 Issue #9632: Remove sys.setfilesystemencoding() function: use PYTHONFSENCODING
environment variable to set the filesystem encoding at Python startup.
sys.setfilesystemencoding() creates inconsistencies because it is unable to
reencode all filenames in all objects.
2010-09-10 21:57:59 +00:00
Benjamin Peterson 17689991e6 only catch AttributeError in hasattr() #9666 2010-08-24 03:26:23 +00:00
Victor Stinner 306f0100f3 Issue #6697: Fix a crash if sys.stdin or sys.stdout encoding contain a surrogate
This is *very* unlikely :-)
2010-05-19 01:06:22 +00:00
Victor Stinner b744ba1d14 Issue #8610: Load file system codec at startup, and display a fatal error on
failure. Set the file system encoding to utf-8 (instead of None) if getting
the locale encoding failed, or if nl_langinfo(CODESET) function is missing.
2010-05-15 12:27:16 +00:00
Antoine Pitrou f95a1b3c53 Recorded merge of revisions 81029 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81029 | antoine.pitrou | 2010-05-09 16:46:46 +0200 (dim., 09 mai 2010) | 3 lines

  Untabify C files. Will watch buildbots.
........
2010-05-09 15:52:27 +00:00
Victor Stinner 120c21227a Issue #8226: sys.setfilesystemencoding() raises a LookupError if the encoding
is unknown.
2010-03-25 00:30:28 +00:00
Benjamin Peterson 09259e2043 check PyDict_New() for error 2010-02-27 17:41:13 +00:00