Commit Graph

3408 Commits

Author SHA1 Message Date
Victor Stinner b306d7594f Fix fileutils for Windows
* Don't define _Py_wstat() on Windows, Windows has its own _wstat() function
   with a different API (the stat buffer has another type)
 * Include windows.h
2010-10-07 22:09:40 +00:00
Victor Stinner e7c8083bf1 Ooops, fileutils.c contains twice the same code
I suppose that I reapplied my local patch creating Python/fileutils.c whereas
the file already existed.
2010-10-07 21:55:44 +00:00
Victor Stinner 4e31443c4d Create fileutils.c/.h
* _Py_fopen() and _Py_stat() come from Python/import.c
 * (_Py)_wrealpath() comes from Python/sysmodule.c
 * _Py_char2wchar(), _Py_wchar2char() and _Py_wfopen() come from Modules/main.c
 * (_Py)_wstat(), (_Py)_wgetcwd(), _Py_wreadlink() come from Modules/getpath.c
2010-10-07 21:45:39 +00:00
Victor Stinner 7ae7c87b05 _wrealpath() and _Py_wreadlink() support surrogates (PEP 383)
Use _Py_wchar2char() to support surrogate characters in the input path.
2010-10-07 11:06:49 +00:00
Victor Stinner beb4135b8c PyUnicode_AsWideCharString() takes a PyObject*, not a PyUnicodeObject*
All unicode functions uses PyObject* except PyUnicode_AsWideChar(). Fix the
prototype for the new function PyUnicode_AsWideCharString().
2010-10-07 01:02:42 +00:00
Victor Stinner c08ec9fdba Create a subfunction for PySys_SetArgvEx()
Create sys_update_path() static function. Do nothing if argc==0.
2010-10-06 22:44:06 +00:00
Amaury Forgeot d'Arc 7955fb638a Merged revisions 85236 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r85236 | amaury.forgeotdarc | 2010-10-06 00:15:37 +0200 (mer., 06 oct. 2010) | 2 lines

  #9060 Let platforms without dup2() compile the replacement fonction without error.
........
2010-10-05 22:18:29 +00:00
Amaury Forgeot d'Arc 90774dd47b #9060 Let platforms without dup2() compile the replacement fonction without error. 2010-10-05 22:15:37 +00:00
Brian Curtin 748cacee46 Remove an unreferenced variable. len is no longer needed. 2010-09-29 19:09:33 +00:00
Victor Stinner c39211f51e Issue #9630: Redecode filenames when setting the filesystem encoding
Redecode the filenames of:

 - all modules: __file__ and __path__ attributes
 - all code objects: co_filename attribute
 - sys.path
 - sys.meta_path
 - sys.executable
 - sys.path_importer_cache (keys)

Keep weak references to all code objects until initfsencoding() is called, to
be able to redecode co_filename attribute of all code objects.
2010-09-29 16:35:47 +00:00
Victor Stinner 255dfdb5ce Issue #9979: Use PyUnicode_AsWideCharString() in import.c
Don't truncate path if it is too long anymore, and allocate fewer memory (but
allocate it on the heap, not on the stack).
2010-09-29 10:28:51 +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
Benjamin Peterson aa7fbd9564 revert r85003, poorly considered; breaks tests 2010-09-25 03:25:42 +00:00
Benjamin Peterson 81437c9025 don't count keyword arguments as positional #9943 2010-09-25 03:14:33 +00:00
Benjamin Peterson d4efd9eb15 add column offset to all syntax errors 2010-09-20 23:02:10 +00:00
Benjamin Peterson 2c53971b37 add PyErr_SyntaxLocationEx, to support adding a column offset 2010-09-20 22:42:10 +00:00
Antoine Pitrou b0b384b7c0 Issue #9901: Destroying the GIL in Py_Finalize() can fail if some other
threads are still running.  Instead, reinitialize the GIL on a second
call to Py_Initialize().
2010-09-20 20:13:48 +00:00
Kristján Valur Jónsson 2fea9b961d issue 9786 Native TLS support for pthreads
PyThread_create_key now has a failure mode that the applicatino can detect.
2010-09-20 02:11:49 +00:00
Brett Cannon bc2eff3112 PyImport_Import was using the old import hack of sticking a dummy value into
fromlist to get __import__ to return the module desired. Now it uses the proper
approach of fetching the module from sys.modules.

Closes issue #9252. Thanks to Alexander Belopolsky for the bug report.
2010-09-19 21:39:02 +00:00
Antoine Pitrou 1df1536fb9 Issue #9828: Destroy the GIL in Py_Finalize(), so that it gets properly
re-created on a subsequent call to Py_Initialize().  The problem (a crash)
wouldn't appear in 3.1 or 2.7 where the GIL's structure is more trivial.
2010-09-13 14:16:46 +00:00
Nick Coghlan cd419abe42 Fix incorrect comment regarding MAGIC and TAG in import.c 2010-09-11 00:39:25 +00:00
Benjamin Peterson e208b7c5b1 typo 2010-09-10 23:53:14 +00:00
Benjamin Peterson d0de25d731 use Py_REFCNT 2010-09-10 23:52:42 +00:00
Benjamin Peterson d2be5b4fe4 remove gil_drop_request in --without-threads 2010-09-10 22:47:02 +00:00
Benjamin Peterson 00ebe2cdc4 use DISPATCH() instead of continue 2010-09-10 22:02:31 +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 6246d6dcb0 bump magic number for DELETE_DEREF 2010-09-10 21:51:44 +00:00
Amaury Forgeot d'Arc ba117ef7e9 #4617: Previously it was illegal to delete a name from the local
namespace if it occurs as a free variable in a nested block.  This limitation
of the compiler has been lifted, and a new opcode introduced (DELETE_DEREF).

This sample was valid in 2.6, but fails to compile in 3.x without this change::

   >>> def f():
   ...     def print_error():
   ...        print(e)
   ...     try:
   ...        something
   ...     except Exception as e:
   ...        print_error()
   ...        # implicit "del e" here


This sample has always been invalid in Python, and now works::

   >>> def outer(x):
   ...     def inner():
   ...        return x
   ...     inner()
   ...     del x

There is no need to bump the PYC magic number: the new opcode is used
for code that did not compile before.
2010-09-10 21:39:53 +00:00
Daniel Stutzbach c7937791a1 Fix Issue #9752: MSVC compiler warning due to undefined function
(Patch by Jon Anglin)
2010-09-09 21:18:04 +00:00
Antoine Pitrou c9a8df24cc Merged revisions 84655 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r84655 | antoine.pitrou | 2010-09-09 22:30:23 +0200 (jeu., 09 sept. 2010) | 6 lines

  Issue #9804: ascii() now always represents unicode surrogate pairs as
  a single `\UXXXXXXXX`, regardless of whether the character is printable
  or not.  Also, the "backslashreplace" error handler now joins surrogate
  pairs into a single character on UCS-2 builds.
........
2010-09-09 20:33:43 +00:00
Antoine Pitrou e4a189274f Issue #9804: ascii() now always represents unicode surrogate pairs as
a single `\UXXXXXXXX`, regardless of whether the character is printable
or not.  Also, the "backslashreplace" error handler now joins surrogate
pairs into a single character on UCS-2 builds.
2010-09-09 20:30:23 +00:00
Matthias Klose f69af1e959 PEP 3149: Try to load the extension with the SOABI before trying
to load the one without the SOABI in the name.
2010-09-08 16:22:10 +00:00
Antoine Pitrou 3c6261a90b Merged revisions 84623 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r84623 | antoine.pitrou | 2010-09-08 14:37:10 +0200 (mer., 08 sept. 2010) | 4 lines

  Issue #9797: pystate.c wrongly assumed that zero couldn't be a valid
  thread-local storage key.
........
2010-09-08 12:48:12 +00:00
Antoine Pitrou 079ce54efe Issue #9797: pystate.c wrongly assumed that zero couldn't be a valid
thread-local storage key.
2010-09-08 12:37:10 +00:00
Antoine Pitrou 74a69fa662 Issue #9225: Remove the ROT_FOUR and DUP_TOPX opcode, the latter replaced
by the new (and simpler) DUP_TOP_TWO.  Performance isn't changed, but
our bytecode is a bit simplified.  Patch by Demur Rumed.
2010-09-04 18:43:52 +00:00
Brett Cannon ef0e6c3b04 _warnings exposed two variables with the name 'default_action' and
'once_registry'. This is bad as the warnings module had variables named
'defaultaction' and 'onceregistry' which are what people should be looking at
(technically those variables shouldn't be mucked with as they are undocumented,
but we all know better than to believe that isn't happening). So the variables
from _warnings have been renamed to come off as private and to avoid confusion
over what variable should be used.

Closes issue #9766. Thanks to Antoine Pitrou for the discovery.
2010-09-04 18:24:04 +00:00
Barry Warsaw 35f3a2cbeb PEP 3149 is accepted.
http://mail.python.org/pipermail/python-dev/2010-September/103408.html
2010-09-03 18:30:30 +00:00
Antoine Pitrou fce7fd6426 Issue #9549: sys.setdefaultencoding() and PyUnicode_SetDefaultEncoding()
are now removed, since their effect was inexistent in 3.x (the default
encoding is hardcoded to utf-8 and cannot be changed).
2010-09-01 18:54:56 +00:00
Benjamin Peterson 17689991e6 only catch AttributeError in hasattr() #9666 2010-08-24 03:26:23 +00:00
Raymond Hettinger 819a064556 Issue 8403: Don't mask KeyboardInterrupt during peephole operation. 2010-08-22 08:39:49 +00:00
Amaury Forgeot d'Arc a1e5c69d5b Merged revisions 84214 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r84214 | amaury.forgeotdarc | 2010-08-19 23:32:38 +0200 (jeu., 19 août 2010) | 3 lines

  Add tests for r84209 (crashes in the Ast builder)
  Also remove one tab, and move a check closer to the possible failure.
........
2010-08-19 21:35:59 +00:00
Amaury Forgeot d'Arc 12844e6df6 Add tests for r84209 (crashes in the Ast builder)
Also remove one tab, and move a check closer to the possible failure.
2010-08-19 21:32:38 +00:00
Amaury Forgeot d'Arc fc34ac5fdd Merged revisions 84209 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r84209 | amaury.forgeotdarc | 2010-08-19 19:43:15 +0200 (jeu., 19 août 2010) | 5 lines

  Check the return values for all functions returning an ast node.
  Failure to do it may result in strange error messages or even crashes,
  in admittedly convoluted cases that are normally syntax errors, like:
      def f(*xx, __debug__): pass
........
2010-08-19 20:26:00 +00:00
Amaury Forgeot d'Arc 92dc80a8d8 Check the return values for all functions returning an ast node.
Failure to do it may result in strange error messages or even crashes,
in admittedly convoluted cases that are normally syntax errors, like:
    def f(*xx, __debug__): pass
2010-08-19 17:43:15 +00:00
Victor Stinner 94908bbc15 Issue #8622: Add PYTHONFSENCODING environment variable to override the
filesystem encoding.

initfsencoding() displays also a better error message if get_codeset() failed.
2010-08-18 21:23:25 +00:00
Victor Stinner 6b06da5395 Remove unused functions _PyImport_FindModule and _PyImport_IsScript 2010-08-17 22:54:21 +00:00
Victor Stinner 6961bd690e Issue #8063: Call _PyGILState_Init() earlier in Py_InitializeEx(). 2010-08-17 22:26:51 +00:00
Nick Coghlan d26c18adcc Issue #8202: Set sys.argv[0] to -m rather than -c while searching for the module to execute. Also updates all the cmd_line_script tests to validate the setting of sys.path[0] and the current working directory 2010-08-17 13:06:11 +00:00
Victor Stinner 4a3733d160 Issue #9425: save/restore exception on filename encoding
_PyUnicode_AsString() raises an exception on unencodable filename.
2010-08-17 00:39:57 +00:00
Florent Xicluna 2760a66b69 Merged revisions 81214,82302,82465,83090-83091,84097,84099 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r81214 | brett.cannon | 2010-05-16 00:20:16 +0200 (dim., 16 mai 2010) | 2 lines

  A test was not guaranteeing cleanup in the face of an exception.
................
  r82302 | benjamin.peterson | 2010-06-28 00:37:28 +0200 (lun., 28 juin 2010) | 15 lines

  Merged revisions 81380 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r81380 | brett.cannon | 2010-05-20 13:37:55 -0500 (Thu, 20 May 2010) | 8 lines

    Turned out that if you used explicit relative import syntax
    (e.g. from .os import sep) and it failed, import would still try the implicit
    relative import semantics of an absolute import (from os import sep). That's
    not right, so when level is negative, only do explicit relative import
    semantics.

    Fixes issue #7902. Thanks to Meador Inge for the patch.
  ........
................
  r82465 | brett.cannon | 2010-07-03 03:32:48 +0200 (sam., 03 juil. 2010) | 3 lines

  Make test_import a little bit more robust for cleaning up after itself in the
  face of a failure.
................
  r83090 | brett.cannon | 2010-07-23 16:03:16 +0200 (ven., 23 juil. 2010) | 4 lines

  Explicitly test relative imports by reusing importlib tests.

  Closes issue 8392. Thanks Virgil Dupras for the initial patch.
................
  r83091 | brett.cannon | 2010-07-23 16:45:19 +0200 (ven., 23 juil. 2010) | 1 line

  Stop shadowing a test class.
................
  r84097 | florent.xicluna | 2010-08-16 20:41:19 +0200 (lun., 16 août 2010) | 1 line

  Use test.support and unittest features.  Fix duplicated test (bad merge in r79033).  Fix comment for issue #7902.
................
  r84099 | florent.xicluna | 2010-08-16 21:03:05 +0200 (lun., 16 août 2010) | 1 line

  I get it wrong in r84097: s/relative/absolute/
................
2010-08-16 22:40:45 +00:00
Victor Stinner 79766636b6 Issue #9599: Create PySys_FormatStdout() and PySys_FormatStderr()
Write a message formatted by PyUnicode_FromFormatV() to sys.stdout and
sys.stderr.
2010-08-16 17:36:42 +00:00
Victor Stinner f52b705be4 Create _Py_fopen() for PyUnicodeObject path
Call _wfopen() on Windows, or fopen() otherwise. Return the new file object on
success, or NULL if the file cannot be open or (if PyErr_Occurred()) on unicode
error.
2010-08-14 17:06:04 +00:00
Victor Stinner 8a79dccc48 _Py_stat(): ensure that path ends with a nul character 2010-08-14 16:59:08 +00:00
Victor Stinner 4f4402c4bb Issue #9425: Create private _Py_stat() function
Use stat() or _wstat() depending on the OS.
2010-08-14 14:50:26 +00:00
Antoine Pitrou 042b128f58 Issue #9203: Computed gotos are now enabled by default on supported
compilers (which are detected by the configure script).  They can still
be disable selectively by specifying --without-computed-gotos.
2010-08-13 21:15:58 +00:00
Victor Stinner 4a2b7a1b14 Issue #9425: Create PyErr_WarnFormat() function
Similar to PyErr_WarnEx() but use PyUnicode_FromFormatV() to format the warning
message.

Strip also some trailing spaces.
2010-08-13 14:03:48 +00:00
Victor Stinner 1a4d12d746 Issue #9425: NullImporter constructor is fully unicode compliant
* On non-Windows OSes: the constructor accepts bytes filenames
   and use surrogateescape for unicode filenames
 * On Windows: use GetFileAttributesW() instead of GetFileAttributesA()
2010-08-13 13:07:29 +00:00
Alexander Belopolsky f0f45142d5 Issue #2443: Added a new macro, Py_VA_COPY, which is equivalent to C99
va_copy, but available on all python platforms.  Untabified a few
unrelated files.
2010-08-11 17:31:17 +00:00
Antoine Pitrou e1dd1747e8 Issue #8411: new condition variable emulation under Windows for the new GIL,
by Kristján.  Unfortunately the 3.x Windows buildbots are in a wreck, so we'll
have to watch them when they become fit again.
2010-08-10 13:48:51 +00:00
Victor Stinner 44c6c155d6 Issue #9425: Create load_builtin() subfunction
Just move the code and some variables.
2010-08-09 00:59:10 +00:00
Antoine Pitrou 696e03553b Issue #477863: Print a warning at shutdown if gc.garbage is not empty. 2010-08-08 22:18:46 +00:00
Victor Stinner 2e5f1178ac Issue #9425: fix setup_context() for non-ascii filenames
setup_context() replaces .pyc or .pyo filename suffix by .py, but it
didn't work if the filename contains a non-ascii character because the
function used the wrong unit for the length (number of characters
instead of the number of bytes).

With this patch, it uses unicode filenames instead of bytes filenames,
to fix the bug and to be fully unicode compliant.
2010-08-08 22:12:45 +00:00
Antoine Pitrou b61d5c9758 Merged revisions 83854 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r83854 | antoine.pitrou | 2010-08-08 22:46:42 +0200 (dim., 08 août 2010) | 4 lines

  Issue #5319: Print an error if flushing stdout fails at interpreter
  shutdown.
........
2010-08-08 20:49:19 +00:00
Antoine Pitrou bddc9fe22b Issue #5319: Print an error if flushing stdout fails at interpreter
shutdown.
2010-08-08 20:46:42 +00:00
Alexander Belopolsky 6fc4ade2bb Issue #9079: Added _PyTime_gettimeofday(_PyTime_timeval *tp) to C API
exposed in Python.h.  This function is similar to POSIX
gettimeofday(struct timeval *tp), but available on platforms without
gettimeofday().
2010-08-05 17:34:27 +00:00
Georg Brandl 611f8f5e8e Merged revisions 83352,83355-83358,83362,83366,83368-83369 via svnmerge from
svn+ssh://svn.python.org/python/branches/py3k

........
  r83352 | georg.brandl | 2010-07-31 20:11:07 +0200 (Sa, 31 Jul 2010) | 1 line

  #9440: Remove borderline test case that fails based on unpredictable conditions such as compiler flags.
........
  r83355 | georg.brandl | 2010-07-31 21:17:11 +0200 (Sa, 31 Jul 2010) | 1 line

  Fix bad merge: test_support -> support.
........
  r83356 | georg.brandl | 2010-07-31 21:29:15 +0200 (Sa, 31 Jul 2010) | 1 line

  Remove trailing whitespace.
........
  r83357 | georg.brandl | 2010-07-31 21:59:55 +0200 (Sa, 31 Jul 2010) | 1 line

  #5778: document that sys.version can contain a newline.
........
  r83358 | georg.brandl | 2010-07-31 22:05:31 +0200 (Sa, 31 Jul 2010) | 1 line

  #9442: do not document a specific format for sys.version; rather refer to version_info and the platform module.
........
  r83362 | georg.brandl | 2010-07-31 23:12:15 +0200 (Sa, 31 Jul 2010) | 1 line

  #8910: add a file explaining why Lib/test/data is there.
........
  r83366 | georg.brandl | 2010-07-31 23:26:40 +0200 (Sa, 31 Jul 2010) | 1 line

  There always is a False and True now.
........
  r83368 | georg.brandl | 2010-07-31 23:40:15 +0200 (Sa, 31 Jul 2010) | 1 line

  #7909: the prefixes \\.\ and \\?\ indicate special Windows paths, do not try to manipulate them.  See http://msdn.microsoft.com/en-us/library/aa365247%28VS.85%29.aspx for details.
........
  r83369 | georg.brandl | 2010-07-31 23:41:42 +0200 (Sa, 31 Jul 2010) | 1 line

  Fix "Berkeley" name.
........
2010-08-01 19:17:57 +00:00
Georg Brandl e87c0e1eaf Remove trailing whitespace. 2010-07-31 19:29:15 +00:00
Georg Brandl fff9021f75 Update copyright years and add releases to release list. Also update Sphinx version number. 2010-07-31 09:01:16 +00:00
Victor Stinner 8182b717db Issue #8991: convertbuffer() rejects discontigious buffers 2010-07-28 00:40:58 +00:00
Benjamin Peterson 20f9c3c50f revert unintended changes 2010-07-20 22:39:34 +00:00
Benjamin Peterson 013783c529 move test_trace.py so as not to conflict with future tests for the trace module 2010-07-20 22:37:19 +00:00
Mark Dickinson 0bddfd0a53 Regenerate Python/graminit.c. 2010-07-12 14:18:21 +00:00
Georg Brandl 0310a83e7f #3071: tell how many values were expected when unpacking too many. 2010-07-10 10:32:36 +00:00
Mark Dickinson f719733b7d Revert temporary debugging commits (r82752, r82754). 2010-07-09 22:12:52 +00:00
Mark Dickinson 29241eed56 Another temporary checkin to diagnose test_float failure on 3.1 Ubuntu buildbot. 2010-07-09 20:10:37 +00:00
Mark Dickinson 6f826469bb Temporary checkin to try to diagnose i386 Ubuntu buildbot failure. 2010-07-09 19:43:26 +00:00
Matthias Klose d885e95be4 - sysmodule.c (get_hash_info): Define as static function. 2010-07-06 10:53:30 +00:00
Mark Dickinson ce5b6c43bf Revert r82044, since it changed the semantics of negated imaginary literals.
Before r82044, '-7j' became complex(0.0, -7.0);  afterwards it was
complex(-0.0, -7.0).  See issue 9011.
2010-06-30 10:34:53 +00:00
Benjamin Peterson 7ab4b8d3a2 Merged revisions 77402,77505,77510 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77402 | brett.cannon | 2010-01-09 20:56:19 -0600 (Sat, 09 Jan 2010) | 12 lines

  DeprecationWarning is now silent by default.

  This was originally suggested by Guido, discussed on the stdlib-sig mailing
  list, and given the OK by Guido directly to me. What this change essentially
  means is that Python has taken a policy of silencing warnings that are only
  of interest to developers by default. This should prevent users from seeing
  warnings which are triggered by an application being run against a new
  interpreter before the app developer has a chance to update their code.

  Closes issue #7319. Thanks to Antoine Pitrou, Ezio Melotti, and Brian Curtin
  for helping with the issue.
........
  r77505 | brett.cannon | 2010-01-14 14:00:28 -0600 (Thu, 14 Jan 2010) | 7 lines

  The silencing of DeprecationWarning was not taking -3 into consideration. Since
  Py3K warnings are DeprecationWarning by default this was causing -3 to
  essentially be a no-op. Now DeprecationWarning is only silenced if -3 is not
  used.

  Closes issue #7700. Thanks Ezio Melotti and Florent Xicluna for patch help.
........
  r77510 | brett.cannon | 2010-01-14 19:31:45 -0600 (Thu, 14 Jan 2010) | 1 line

  Remove C++/C99-style comments.
........
2010-06-28 00:01:59 +00:00
Benjamin Peterson 556d8001df Merged revisions 81380 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81380 | brett.cannon | 2010-05-20 13:37:55 -0500 (Thu, 20 May 2010) | 8 lines

  Turned out that if you used explicit relative import syntax
  (e.g. from .os import sep) and it failed, import would still try the implicit
  relative import semantics of an absolute import (from os import sep). That's
  not right, so when level is negative, only do explicit relative import
  semantics.

  Fixes issue #7902. Thanks to Meador Inge for the patch.
........
2010-06-27 22:37:28 +00:00
Benjamin Peterson 3e5cd1d04e Merged revisions 81465-81466,81468,81679,81735,81760,81868,82183 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81465 | georg.brandl | 2010-05-22 06:29:19 -0500 (Sat, 22 May 2010) | 2 lines

  Issue #3924: Ignore cookies with invalid "version" field in cookielib.
........
  r81466 | georg.brandl | 2010-05-22 06:31:16 -0500 (Sat, 22 May 2010) | 1 line

  Underscore the name of an internal utility function.
........
  r81468 | georg.brandl | 2010-05-22 06:43:25 -0500 (Sat, 22 May 2010) | 1 line

  #8635: document enumerate() start parameter in docstring.
........
  r81679 | benjamin.peterson | 2010-06-03 16:21:03 -0500 (Thu, 03 Jun 2010) | 1 line

  use a set for membership testing
........
  r81735 | michael.foord | 2010-06-05 06:46:59 -0500 (Sat, 05 Jun 2010) | 1 line

  Extract error message truncating into a method (unittest.TestCase._truncateMessage).
........
  r81760 | michael.foord | 2010-06-05 14:38:42 -0500 (Sat, 05 Jun 2010) | 1 line

  Issue 8302. SkipTest exception is setUpClass or setUpModule is now reported as a skip rather than an error.
........
  r81868 | benjamin.peterson | 2010-06-09 14:45:04 -0500 (Wed, 09 Jun 2010) | 1 line

  fix code formatting
........
  r82183 | benjamin.peterson | 2010-06-23 15:29:26 -0500 (Wed, 23 Jun 2010) | 1 line

  cpython only gc tests
........
2010-06-27 21:45:24 +00:00
Benjamin Peterson 88968ad380 only take into account positional arguments count in related error messages 2010-06-25 19:30:21 +00:00
Victor Stinner 25e8ec4724 Issue #8850: Remove "w" and "w#" formats from PyArg_Parse*() functions, use
"w*" format instead. Add tests for "w*" format.
2010-06-25 00:02:38 +00:00
Victor Stinner 174799912f Issue #8926: getargs.c: release the buffer on error
- "t#" format: don't get the buffer if the object is not a pinned buffer
 - getbuffer(): release the buffer on error

(Commit based on r82206 from py3k)
2010-06-24 23:06:25 +00:00
Victor Stinner 21e09487ac getbuffer(): release the buffer on error (if the buffer is not contiguous) 2010-06-24 22:57:10 +00:00
Victor Stinner 3c9e6e9375 PyArg_Parse*() functions: factorize code for s/z and u/Z formats 2010-06-24 22:31:12 +00:00
Victor Stinner 4aae1ebab2 Issue #8949: "z" format of PyArg_Parse*() functions doesn't accept bytes
objects, as described in the documentation.
2010-06-24 22:08:25 +00:00
Alexander Belopolsky 1b7046b99e Issue #9051: Instances of timezone class can now be pickled. 2010-06-23 21:40:15 +00:00
Stefan Krah c87901d56c Merged revisions 82181 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r82181 | stefan.krah | 2010-06-23 20:42:39 +0200 (Wed, 23 Jun 2010) | 3 lines

  Issue #8930: Remaining indentation fixes after the Grand Unified Indenting.
........
2010-06-23 18:54:09 +00:00
Stefan Krah b7e1010096 Issue #8930: Remaining indentation fixes after the Grand Unified Indenting. 2010-06-23 18:42:39 +00:00
Antoine Pitrou 252e8e2f61 Merged revisions 82171 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r82171 | antoine.pitrou | 2010-06-22 23:49:39 +0200 (mar., 22 juin 2010) | 10 lines

  Merged revisions 82169 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r82169 | antoine.pitrou | 2010-06-22 23:42:05 +0200 (mar., 22 juin 2010) | 4 lines

    Fix misindents in compile.c (for Benjamin).
    Of course, whoever used the wrong indentation rules needs to be spanked.
  ........
................
2010-06-22 21:53:47 +00:00
Antoine Pitrou 9aee2c81ea Merged revisions 82169 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r82169 | antoine.pitrou | 2010-06-22 23:42:05 +0200 (mar., 22 juin 2010) | 4 lines

  Fix misindents in compile.c (for Benjamin).
  Of course, whoever used the wrong indentation rules needs to be spanked.
........
2010-06-22 21:49:39 +00:00
Victor Stinner 25bb0fdb67 Merged revisions 82059,82061 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r82059 | victor.stinner | 2010-06-18 01:08:50 +0200 (ven., 18 juin 2010) | 5 lines

  Issue #6543: Write the traceback in the terminal encoding instead of utf-8.
  Fix the encoding of the modules filename.

  Reindent also traceback.h, just because I hate tabs :-)
........
  r82061 | victor.stinner | 2010-06-18 01:17:37 +0200 (ven., 18 juin 2010) | 2 lines

  Issue #6543: Mention the author of the patch, Amaury Forgeot d'Arc
........
2010-06-17 23:23:37 +00:00
Victor Stinner 0fe25a445d Issue #6543: Write the traceback in the terminal encoding instead of utf-8.
Fix the encoding of the modules filename.

Reindent also traceback.h, just because I hate tabs :-)
2010-06-17 23:08:50 +00:00
Barry Warsaw 7c9627b4de Typo repair. 2010-06-17 18:38:20 +00:00
Mark Dickinson a58eed9cca Merged revisions 82043 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r82043 | mark.dickinson | 2010-06-17 13:33:22 +0100 (Thu, 17 Jun 2010) | 6 lines

  Issue #9011: Remove buggy and unnecessary ST->AST compilation code
  dealing with unary minus applied to a constant.  The removed code was
  mutating the ST, causing a second compilation to fail.  (The peephole
  optimizer already takes care of optimizing this case, so there's no
  lost optimization opportunity here.)
........
2010-06-17 12:37:17 +00:00
Mark Dickinson d35a32e12e Issue #9011: Remove buggy and unnecessary ST->AST compilation code
dealing with unary minus applied to a constant.  The removed code was
mutating the ST, causing a second compilation to fail.  (The peephole
optimizer already takes care of optimizing this case, so there's no
lost optimization opportunity here.)
2010-06-17 12:33:22 +00:00
Victor Stinner 510b6227a7 getargs.c: remove last reference to "t#" format
"t#" format was removed from convertitem() (convertsimple) but not skipitem().
2010-06-13 20:31:26 +00:00
Victor Stinner 06e49dd029 Issue #8592: PyArg_Parse*() functions raise a TypeError for "y", "u" and "Z"
formats if the string contains a null byte/character. Write unit tests for
string formats.
2010-06-13 18:21:50 +00:00
Benjamin Peterson c629d51ea9 Merged revisions 81906 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81906 | benjamin.peterson | 2010-06-11 16:40:37 -0500 (Fri, 11 Jun 2010) | 1 line

  different spellings are just unacceptable
........
2010-06-11 21:53:07 +00:00
Victor Stinner 7f84ab5952 Issue #8965: initfsencoding() doesn't change the encoding on Mac OS X
File system encoding have to be hardcoded to "utf-8" on Mac OS X. r81190
introduced a regression: the encoding was changed depending on the locale.
2010-06-11 00:36:33 +00:00
Mark Dickinson c73013127b Issue #8950: Make PyArg_Parse* with 'L' code raise for float inputs,
instead of warning.  This makes it consistent with the other integer
codes.
2010-06-10 16:05:10 +00:00
Victor Stinner 3dcb5acdb0 Issue #8838, #8339: Remove codecs.charbuffer_encode() and "t#" parsing format
Remove last references to the "char buffer" of the buffer protocol from
Python3.
2010-06-08 22:54:19 +00:00
Victor Stinner 55b002f096 Merged revisions 81849 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r81849 | victor.stinner | 2010-06-08 23:45:51 +0200 (mar., 08 juin 2010) | 7 lines

  PyArg_Parse*("Z#") raises an error for unknown type

  instead of ignoring the error and leave the pointer to the string and the size
  unchanged (not initialized).

  Fix also the type in the error message of "Z", "Z#" and "Y" formats.
........
2010-06-08 21:46:32 +00:00
Victor Stinner 5216e6d598 PyArg_Parse*("Z#") raises an error for unknown type
instead of ignoring the error and leave the pointer to the string and the size
unchanged (not initialized).

Fix also the type in the error message of "Z", "Z#" and "Y" formats.
2010-06-08 21:45:51 +00:00
Victor Stinner 93362d4e6b Merged revisions 81844 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r81844 | victor.stinner | 2010-06-08 23:00:13 +0200 (mar., 08 juin 2010) | 6 lines

  Py_FatalError(): don't sys sys.last_xxx variables

  Call PyErr_PrintEx(0) instead of PyErr_Print() to avoid a crash if
  Py_FatalError() is called in an early stage of Python initialization (if PySys
  is not yet initialized).
........
2010-06-08 21:05:20 +00:00
Victor Stinner 55a5c78e4d Py_FatalError(): don't sys sys.last_xxx variables
Call PyErr_PrintEx(0) instead of PyErr_Print() to avoid a crash if
Py_FatalError() is called in an early stage of Python initialization (if PySys
is not yet initialized).
2010-06-08 21:00:13 +00:00
Victor Stinner a01c6b3c9e Merged revisions 81841 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r81841 | victor.stinner | 2010-06-08 22:46:00 +0200 (mar., 08 juin 2010) | 6 lines

  sys_pyfile_write() does nothing if file is NULL

  mywrite() falls back to the C file object if sys_pyfile_write() returns an
  error. This patch fixes a segfault is Py_FatalError() is called in an early
  stage of Python initialization.
........
2010-06-08 20:50:09 +00:00
Victor Stinner ecccc4f9b8 sys_pyfile_write() does nothing if file is NULL
mywrite() falls back to the C file object if sys_pyfile_write() returns an
error. This patch fixes a segfault is Py_FatalError() is called in an early
stage of Python initialization.
2010-06-08 20:46:00 +00:00
Victor Stinner 7eeb5b5e50 Issue #8848: U / U# formats of Py_BuildValue() are just alias to s / s# 2010-06-07 19:57:46 +00:00
Victor Stinner 2872e5b1f8 convertsimple(): call PyErr_NoMemory() on PyMem_NEW() failure
Raise a more revelant error (MemoryError instead of TypeError)
2010-06-06 20:38:02 +00:00
Victor Stinner 5cb6239f00 Simplify getbuffer(): convertbuffer() fails anyway if bf_getbuffer is NULL 2010-06-06 20:27:51 +00:00
Benjamin Peterson 08ec84cf72 use atomic structures in non-thread version 2010-05-30 14:49:32 +00:00
Victor Stinner 43fb0097f3 Remove dead code 2010-05-29 00:13:06 +00:00
Victor Stinner 33109a142b Issue #8837: Remove "O?" format of PyArg_Parse*() functions. The format is no
used anymore and it was never documented.
2010-05-28 21:55:10 +00:00
Mark Dickinson dc787d2055 Issue #8188: Introduce a new scheme for computing hashes of numbers
(instances of int, float, complex, decimal.Decimal and
fractions.Fraction) that makes it easy to maintain the invariant that
hash(x) == hash(y) whenever x and y have equal value.
2010-05-23 13:33:13 +00:00
Victor Stinner 7126dbc867 Issue #3798: sys.exit(message) writes the message to sys.stderr file, instead
of the C file stderr, to use stderr encoding and error handler
2010-05-21 23:45:42 +00:00
Antoine Pitrou 71d305c83d Merged revisions 81400 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r81400 | antoine.pitrou | 2010-05-21 19:25:34 +0200 (ven., 21 mai 2010) | 12 lines

  Merged revisions 81398 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r81398 | antoine.pitrou | 2010-05-21 19:12:38 +0200 (ven., 21 mai 2010) | 6 lines

    Issue #5753: A new C API function, :cfunc:`PySys_SetArgvEx`, allows
    embedders of the interpreter to set sys.argv without also modifying
    sys.path.  This helps fix `CVE-2008-5983
    <http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2008-5983>`_.
  ........
................
2010-05-21 17:33:14 +00:00
Antoine Pitrou f978facc0e Merged revisions 81398 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81398 | antoine.pitrou | 2010-05-21 19:12:38 +0200 (ven., 21 mai 2010) | 6 lines

  Issue #5753: A new C API function, :cfunc:`PySys_SetArgvEx`, allows
  embedders of the interpreter to set sys.argv without also modifying
  sys.path.  This helps fix `CVE-2008-5983
  <http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2008-5983>`_.
........
2010-05-21 17:25:34 +00:00
Victor Stinner 148051a054 Recorded merge of revisions 81364 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r81364 | victor.stinner | 2010-05-19 22:40:50 +0200 (mer., 19 mai 2010) | 3 lines

  Issue #8766: Initialize _warnings module before importing the first module.
  Fix a crash if an empty directory called "encodings" exists in sys.path.
........
2010-05-20 21:00:34 +00:00
Victor Stinner 7d79b8b771 Issue #8766: Initialize _warnings module before importing the first module.
Fix a crash if an empty directory called "encodings" exists in sys.path.
2010-05-19 20:40:50 +00:00
Victor Stinner 9ca9c25bcd Issue #8589: Decode PYTHONWARNINGS environment variable with the file system
encoding and surrogateespace error handler instead of the locale encoding to be
consistent with os.environ. Add PySys_AddWarnOptionUnicode() function.
2010-05-19 16:53:30 +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 93b5513cf1 Issue #6697: Fix a crash if a keyword contains a surrogate 2010-05-19 00:54:06 +00:00
Victor Stinner 386fe71de1 Issue #6697: Check that _PyUnicode_AsString() result is not NULL 2010-05-19 00:34:15 +00:00
Victor Stinner 2e71d014ea Merged revisions 81250-81253 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r81250 | victor.stinner | 2010-05-17 03:13:37 +0200 (lun., 17 mai 2010) | 2 lines

  Issue #6697: Fix a crash if code of "python -c code" contains surrogates
........
  r81251 | victor.stinner | 2010-05-17 03:26:01 +0200 (lun., 17 mai 2010) | 3 lines

  PyObject_Dump() encodes unicode objects to utf8 with backslashreplace (instead
  of strict) error handler to escape surrogates
........
  r81252 | victor.stinner | 2010-05-17 10:58:51 +0200 (lun., 17 mai 2010) | 6 lines

  handle_system_exit() flushs files to warranty the output order

  PyObject_Print() writes into the C object stderr, whereas PySys_WriteStderr()
  writes into the Python object sys.stderr. Each object has its own buffer, so
  call sys.stderr.flush() and fflush(stderr).
........
  r81253 | victor.stinner | 2010-05-17 11:33:42 +0200 (lun., 17 mai 2010) | 6 lines

  Fix refleak in internal_print() introduced by myself in r81251

  _PyUnicode_AsDefaultEncodedString() uses a magical PyUnicode attribute to
  automatically destroy PyUnicode_EncodeUTF8() result when the unicode string is
  destroyed.
........
2010-05-17 09:35:44 +00:00
Victor Stinner e9fb319e68 handle_system_exit() flushs files to warranty the output order
PyObject_Print() writes into the C object stderr, whereas PySys_WriteStderr()
writes into the Python object sys.stderr. Each object has its own buffer, so
call sys.stderr.flush() and fflush(stderr).
2010-05-17 08:58:51 +00:00
Victor Stinner 0ac51bd1b6 Merged revisions 81222 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r81222 | victor.stinner | 2010-05-16 01:00:51 +0200 (dim., 16 mai 2010) | 11 lines

  Merged revisions 81220 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r81220 | victor.stinner | 2010-05-16 00:55:28 +0200 (dim., 16 mai 2010) | 4 lines

    Use 4-spaces for indentation (instead of tabs) in pgen outputs

    Regenerate (reindent) Python/graminit.c
  ........
................
2010-05-15 23:03:15 +00:00
Victor Stinner beba826023 Merged revisions 81220 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81220 | victor.stinner | 2010-05-16 00:55:28 +0200 (dim., 16 mai 2010) | 4 lines

  Use 4-spaces for indentation (instead of tabs) in pgen outputs

  Regenerate (reindent) Python/graminit.c
........
2010-05-15 23:00:51 +00:00
Victor Stinner ae6265f8d0 Issue #8715: Create PyUnicode_EncodeFSDefault() function: Encode a Unicode
object to Py_FileSystemDefaultEncoding with the "surrogateescape" error
handler, return a bytes object. If Py_FileSystemDefaultEncoding is not set,
fall back to UTF-8.
2010-05-15 16:27:27 +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
Victor Stinner ebb5a88fd6 Merged revisions 81156 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r81156 | victor.stinner | 2010-05-14 02:59:09 +0200 (ven., 14 mai 2010) | 5 lines

  Issue #4653: fix typo in flush_std_files()

  Don't call sys.stderr.flush() if sys has no stderr attribute or if
  sys.stderr==None.
........
2010-05-14 01:03:14 +00:00
Victor Stinner 9467b212f5 Issue #4653: fix typo in flush_std_files()
Don't call sys.stderr.flush() if sys has no stderr attribute or if
sys.stderr==None.
2010-05-14 00:59:09 +00:00
Jeffrey Yasskin 8e0bdfd1d4 Make PyErr_Occurred return NULL if there is no current thread. Previously it
would Py_FatalError, which called PyErr_Occurred, resulting in a semi-infinite
recursion.

Fixes issue 3605.
2010-05-13 18:31:05 +00:00
Mark Dickinson d3697262f4 Remove unnecessary assignments. 2010-05-13 11:52:22 +00:00
Antoine Pitrou 7f14f0d8a0 Recorded merge of revisions 81032 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r81032 | antoine.pitrou | 2010-05-09 17:52:27 +0200 (dim., 09 mai 2010) | 9 lines

  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 16:14:21 +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
Jean-Paul Calderone 9c39bc7265 Merged revisions 81016 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r81016 | jean-paul.calderone | 2010-05-08 23:18:57 -0400 (Sat, 08 May 2010) | 9 lines

  Merged revisions 81007 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r81007 | jean-paul.calderone | 2010-05-08 16:06:02 -0400 (Sat, 08 May 2010) | 1 line

    Skip signal handler re-installation if it is not necessary.  Issue 8354.
  ........
................
2010-05-09 03:25:16 +00:00
Jean-Paul Calderone 6f137ca469 Merged revisions 81007 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r81007 | jean-paul.calderone | 2010-05-08 16:06:02 -0400 (Sat, 08 May 2010) | 1 line

  Skip signal handler re-installation if it is not necessary.  Issue 8354.
........
2010-05-09 03:18:57 +00:00
Victor Stinner 8d93e49a93 PyErr_SetFromErrnoWithFilename() decodes the filename using
PyUnicode_DecodeFSDefault() instead of PyUnicode_FromString()
2010-05-08 00:35:33 +00:00
Victor Stinner b001df0040 err_input(): don't encode/decode the unicode message 2010-05-08 00:07:07 +00:00
Benjamin Peterson 70cce42f15 read eval_breaker with atomic api with computed gotos 2010-05-03 21:09:59 +00:00
Jeffrey Yasskin 39370830a9 Make (most of) Python's tests pass under Thread Sanitizer.
http://code.google.com/p/data-race-test/wiki/ThreadSanitizer is a dynamic data
race detector that runs on top of valgrind. With this patch, the binaries at
http://code.google.com/p/data-race-test/wiki/ThreadSanitizer#Binaries pass many
but not all of the Python tests. All of regrtest still passes outside of tsan.

I've implemented part of the C1x atomic types so that we can explicitly mark
variables that are used across threads, and get defined behavior as compilers
advance.

I've added tsan's client header and implementation to the codebase in
dynamic_annotations.{h,c} (docs at
http://code.google.com/p/data-race-test/wiki/DynamicAnnotations).
Unfortunately, I haven't been able to get helgrind and drd to give sensible
error messages, even when I use their client annotations, so I'm not supporting
them.
2010-05-03 19:29:34 +00:00
Benjamin Peterson fb88636199 prevent the dict constructor from accepting non-string keyword args #8419
This adds PyArg_ValidateKeywordArguments, which checks that keyword arguments
are all strings, using an optimized method if possible.
2010-04-24 18:21:17 +00:00
Victor Stinner 32366b45e8 Merged revisions 80404 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r80404 | victor.stinner | 2010-04-23 14:02:30 +0200 (ven., 23 avril 2010) | 4 lines

  Issue #8124: PySys_WriteStdout() and PySys_WriteStderr() don't execute
  indirectly Python signal handlers anymore because mywrite() ignores exceptions
  (KeyboardInterrupt).
........
2010-04-23 12:04:53 +00:00
Victor Stinner 14284c2f3b Issue #8124: PySys_WriteStdout() and PySys_WriteStderr() don't execute
indirectly Python signal handlers anymore because mywrite() ignores exceptions
(KeyboardInterrupt).
2010-04-23 12:02:30 +00:00
Antoine Pitrou 5bc7ec9476 Merged revisions 80325 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r80325 | antoine.pitrou | 2010-04-22 00:53:29 +0200 (jeu., 22 avril 2010) | 6 lines

  Issue #7332: Remove the 16KB stack-based buffer in
  PyMarshal_ReadLastObjectFromFile, which doesn't bring any noticeable
  benefit compared to the dynamic memory allocation fallback.  Patch by
  Charles-François Natali.
........
2010-04-21 22:56:22 +00:00
Barry Warsaw 28a691b7fd PEP 3147 2010-04-17 00:19:56 +00:00
Antoine Pitrou 7c3e577395 Issue #7316: the acquire() method of lock objects in the :mod:`threading`
module now takes an optional timeout argument in seconds.  Timeout support
relies on the system threading library, so as to avoid a semi-busy wait
loop.
2010-04-14 15:44:10 +00:00
Antoine Pitrou f96b78437b Merged revisions 79837 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79837 | antoine.pitrou | 2010-04-06 17:38:25 +0200 (mar., 06 avril 2010) | 19 lines

  14 years later, we still don't know what it's for.
  Spotted by the PyPy developers.

  Original commit is:

  branch:      trunk
  user:        guido
  date:        Mon Aug 19 21:32:04 1996 +0200
  files:       Python/getargs.c
  description:
  [svn r6499] Support for keyword arguments (PyArg_ParseTupleAndKeywords) donated by
  Geoff Philbrick <philbric@delphi.hks.com> (slightly changed by me).

  Also a little change to make the file acceptable to K&R C compilers
  (HPUX, SunOS 4.x).
........
2010-04-06 16:01:57 +00:00
Mark Dickinson bee1fb0f75 Merged revisions 78918,78920 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r78918 | mark.dickinson | 2010-03-13 11:34:40 +0000 (Sat, 13 Mar 2010) | 4 lines

  Issue #8014: Fix PyLong_As<c-integer-type> methods not to produce an
  internal error on non-integer input: they now raise TypeError instead.
  This is needed for attributes declared via PyMemberDefs.
........
  r78920 | mark.dickinson | 2010-03-13 13:23:05 +0000 (Sat, 13 Mar 2010) | 3 lines

  Issue #8014: Fix incorrect error checks in structmember.c, and re-enable
  previously failing test_structmember.py tests.
........
2010-04-06 15:44:57 +00:00
Benjamin Peterson deca4b0709 Merged revisions 79765 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r79765 | benjamin.peterson | 2010-04-04 18:09:06 -0500 (Sun, 04 Apr 2010) | 9 lines

  Merged revisions 79763 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r79763 | benjamin.peterson | 2010-04-04 18:03:22 -0500 (Sun, 04 Apr 2010) | 1 line

    fix tabs
  ........
................
2010-04-04 23:18:09 +00:00
Benjamin Peterson c54eec37db Merged revisions 79763 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79763 | benjamin.peterson | 2010-04-04 18:03:22 -0500 (Sun, 04 Apr 2010) | 1 line

  fix tabs
........
2010-04-04 23:09:06 +00:00
Benjamin Peterson bde0c9db80 Merged revisions 79645 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r79645 | benjamin.peterson | 2010-04-02 20:40:24 -0500 (Fri, 02 Apr 2010) | 13 lines

  Merged revisions 79642,79644 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r79642 | benjamin.peterson | 2010-04-02 20:08:34 -0500 (Fri, 02 Apr 2010) | 1 line

    split out large test function
  ........
    r79644 | benjamin.peterson | 2010-04-02 20:28:57 -0500 (Fri, 02 Apr 2010) | 1 line

    give TypeError when trying to set T_STRING_INPLACE
  ........
................
2010-04-03 01:46:38 +00:00
Benjamin Peterson 80d8fd85a9 Merged revisions 79642,79644 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79642 | benjamin.peterson | 2010-04-02 20:08:34 -0500 (Fri, 02 Apr 2010) | 1 line

  split out large test function
........
  r79644 | benjamin.peterson | 2010-04-02 20:28:57 -0500 (Fri, 02 Apr 2010) | 1 line

  give TypeError when trying to set T_STRING_INPLACE
........
2010-04-03 01:40:24 +00:00
Antoine Pitrou 8689a10f07 Merged revisions 79555 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79555 | antoine.pitrou | 2010-04-01 18:42:11 +0200 (jeu., 01 avril 2010) | 5 lines

  Issue #8276: PyEval_CallObject() is now only available in macro form.  The
  function declaration, which was kept for backwards compatibility reasons,
  is now removed (the macro was introduced in 1997!).
........
2010-04-01 16:53:15 +00:00
Benjamin Peterson fa0aebacd9 Merged revisions 79428 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79428 | benjamin.peterson | 2010-03-25 18:27:16 -0500 (Thu, 25 Mar 2010) | 1 line

  make naming convention consistent
........
2010-03-25 23:30:20 +00:00
Victor Stinner d8805b2bb8 Merged revisions 79393 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r79393 | victor.stinner | 2010-03-25 01:30:28 +0100 (jeu., 25 mars 2010) | 3 lines

  Issue #8226: sys.setfilesystemencoding() raises a LookupError if the encoding
  is unknown.
........
2010-03-25 00:35:51 +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
Victor Stinner 1d6af707cf Revert my change on initsite(): don't change import site error handler in 3.1,
as I did for 2.6. But fix the other bugs :-)
2010-03-21 21:57:42 +00:00
Victor Stinner ffbc2f63e1 Merged revisions 78872 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r78872 | victor.stinner | 2010-03-12 15:45:56 +0100 (ven., 12 mars 2010) | 12 lines

  Merged revisions 78826 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r78826 | victor.stinner | 2010-03-10 23:30:19 +0100 (mer., 10 mars 2010) | 5 lines

    Issue #3137: Don't ignore errors at startup, especially a keyboard interrupt
    (SIGINT). If an error occurs while importing the site module, the error is
    printed and Python exits. Initialize the GIL before importing the site
    module.
  ........
................
2010-03-21 21:48:45 +00:00
Benjamin Peterson 7588b8b355 nest if for clarity 2010-03-21 21:22:12 +00:00
Benjamin Peterson afcee8b78d count keyword only arguments as part of the total 2010-03-21 21:16:24 +00:00
Benjamin Peterson f3b7a25a21 Merged revisions 78028 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78028 | benjamin.peterson | 2010-02-06 13:40:18 -0600 (Sat, 06 Feb 2010) | 1 line

  remove pointless error checking
........
2010-03-21 21:12:03 +00:00
Benjamin Peterson 232ecb8918 cleanup a bit 2010-03-21 21:08:54 +00:00
Victor Stinner 38c36f8576 Merged revisions 78875 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r78875 | victor.stinner | 2010-03-12 18:00:41 +0100 (ven., 12 mars 2010) | 5 lines

  Issue #6697: use %U format instead of _PyUnicode_AsString(), because
  _PyUnicode_AsString() was not checked for error (NULL).

  The unicode string is no more truncated to 200 or 400 *bytes*.
........
2010-03-21 21:05:53 +00:00
Benjamin Peterson a567a7796b Merged revisions 79205,79219,79228,79230,79232-79233,79235,79237 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79205 | benjamin.peterson | 2010-03-21 12:34:54 -0500 (Sun, 21 Mar 2010) | 1 line

  rewrite a bit
........
  r79219 | benjamin.peterson | 2010-03-21 14:24:08 -0500 (Sun, 21 Mar 2010) | 1 line

  flatten condition
........
  r79228 | benjamin.peterson | 2010-03-21 14:35:39 -0500 (Sun, 21 Mar 2010) | 1 line

  remove pointless condition
........
  r79230 | benjamin.peterson | 2010-03-21 14:39:52 -0500 (Sun, 21 Mar 2010) | 1 line

  co_varnames is certainly a tuple, so let's not waste time finding out
........
  r79232 | benjamin.peterson | 2010-03-21 14:54:56 -0500 (Sun, 21 Mar 2010) | 1 line

  fix import
........
  r79233 | benjamin.peterson | 2010-03-21 14:56:37 -0500 (Sun, 21 Mar 2010) | 1 line

  don't write duplicate tests
........
  r79235 | benjamin.peterson | 2010-03-21 15:21:00 -0500 (Sun, 21 Mar 2010) | 4 lines

  improve error message from passing inadequate number of keyword arguments #6474

  Note this removes the "non-keyword" or "keyword" phrases from these messages.
........
  r79237 | benjamin.peterson | 2010-03-21 15:30:30 -0500 (Sun, 21 Mar 2010) | 1 line

  take into account keyword arguments when passing too many args
........
2010-03-21 21:00:50 +00:00
Benjamin Peterson e6dd2cb63d Merged revisions 79034 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r79034 | benjamin.peterson | 2010-03-17 15:41:42 -0500 (Wed, 17 Mar 2010) | 1 line

  prevent lambda functions from having docstrings #8164
........
2010-03-17 20:56:58 +00:00
Gregory P. Smith fb94c5f1e5 * Replaces the internals of the subprocess module from fork through exec on
POSIX systems with a C extension module.  This is required in order for
  the subprocess module to be made thread safe.

  The pure python implementation is retained so that it can continue to be
  used if for some reason the _posixsubprocess extension module is not
  available.

  The unittest executes tests on both code paths to guarantee compatibility.

* Moves PyLong_FromPid and PyLong_AsPid from posixmodule.c into longobject.h.

Code reviewed by jeffrey.yasskin at http://codereview.appspot.com/223077/show
2010-03-14 06:49:55 +00:00
Mark Dickinson 252e4003b9 Issue #8014: Fix incorrect error checks in structmember.c, and re-enable
previously failing test_structmember.py tests.
2010-03-13 13:23:05 +00:00
Victor Stinner 3f1af5c42e Issue #6697: use %U format instead of _PyUnicode_AsString(), because
_PyUnicode_AsString() was not checked for error (NULL).

The unicode string is no more truncated to 200 or 400 *bytes*.
2010-03-12 17:00:41 +00:00
Victor Stinner 52f6dd7a3d Merged revisions 78826 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78826 | victor.stinner | 2010-03-10 23:30:19 +0100 (mer., 10 mars 2010) | 5 lines

  Issue #3137: Don't ignore errors at startup, especially a keyboard interrupt
  (SIGINT). If an error occurs while importing the site module, the error is
  printed and Python exits. Initialize the GIL before importing the site
  module.
........
2010-03-12 14:45:56 +00:00
Benjamin Peterson b5cdf191ec fix bootstrapping on machines with only 2.x installed 2010-03-11 23:39:40 +00:00
Benjamin Peterson 90f5ba538b convert shebang lines: python -> python3 2010-03-11 22:53:45 +00:00
Benjamin Peterson d01444d325 Merged revisions 78766 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r78766 | benjamin.peterson | 2010-03-07 11:10:51 -0600 (Sun, 07 Mar 2010) | 1 line

  prevent generator finalization from invalidating sys.exc_info() #7173
........
2010-03-07 17:14:15 +00:00
Benjamin Peterson ae5f2f4a39 prevent generator finalization from invalidating sys.exc_info() #7173 2010-03-07 17:10:51 +00:00
Victor Stinner ef32bc8569 Merged revisions 78639 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r78639 | victor.stinner | 2010-03-04 00:28:07 +0100 (jeu., 04 mars 2010) | 10 lines

  Merged revisions 78638 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r78638 | victor.stinner | 2010-03-04 00:20:25 +0100 (jeu., 04 mars 2010) | 3 lines

    Issue #7544: Preallocate thread memory before creating the thread to avoid a
    fatal error in low memory condition.
  ........
................
2010-03-03 23:32:07 +00:00
Victor Stinner 45b9be52de Merged revisions 78638 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78638 | victor.stinner | 2010-03-04 00:20:25 +0100 (jeu., 04 mars 2010) | 3 lines

  Issue #7544: Preallocate thread memory before creating the thread to avoid a
  fatal error in low memory condition.
........
2010-03-03 23:28:07 +00:00
Florent Xicluna d7494de5bf Merged revisions 78622 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r78622 | florent.xicluna | 2010-03-03 12:54:54 +0100 (mer, 03 mar 2010) | 9 lines

  Merged revisions 78620 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r78620 | florent.xicluna | 2010-03-03 12:49:53 +0100 (mer, 03 mar 2010) | 2 lines

    Revert a nonexistent docstring typo, r42805.
  ........
................
2010-03-03 11:55:53 +00:00
Florent Xicluna 5749e85b53 Merged revisions 78620 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78620 | florent.xicluna | 2010-03-03 12:49:53 +0100 (mer, 03 mar 2010) | 2 lines

  Revert a nonexistent docstring typo, r42805.
........
2010-03-03 11:54:54 +00:00
Gregory P. Smith 24cec9fe07 Merged revisions 78527,78550 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78527 | gregory.p.smith | 2010-02-28 17:22:39 -0800 (Sun, 28 Feb 2010) | 4 lines

  Issue #7242: On Solaris 9 and earlier calling os.fork() from within a
  thread could raise an incorrect RuntimeError about not holding the import
  lock.  The import lock is now reinitialized after fork.
........
  r78550 | gregory.p.smith | 2010-02-28 22:01:02 -0800 (Sun, 28 Feb 2010) | 2 lines

  Fix test to be skipped on windows.
........
2010-03-01 06:18:41 +00:00
Brett Cannon 9a5b25a3ef Strip out trailing whitespace. 2010-03-01 02:09:17 +00:00
Benjamin Peterson 1ca73ede26 Merged revisions 78505-78506 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r78505 | benjamin.peterson | 2010-02-27 11:40:01 -0600 (Sat, 27 Feb 2010) | 1 line

  only accept AttributeError as indicating no __prepare__ attribute on a metaclass, allowing lookup errors to propogate
........
  r78506 | benjamin.peterson | 2010-02-27 11:41:13 -0600 (Sat, 27 Feb 2010) | 1 line

  check PyDict_New() for error
........
2010-02-27 17:56:22 +00:00
Benjamin Peterson 09259e2043 check PyDict_New() for error 2010-02-27 17:41:13 +00:00
Benjamin Peterson 23e018ab98 only accept AttributeError as indicating no __prepare__ attribute on a metaclass, allowing lookup errors to propogate 2010-02-27 17:40:01 +00:00
Amaury Forgeot d'Arc 72aee3dcab Merged revisions 78393 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r78393 | amaury.forgeotdarc | 2010-02-24 00:19:39 +0100 (mer., 24 févr. 2010) | 2 lines

  #4852: Remove dead code in every thread implementation, unused for many years.
........
2010-02-24 00:10:48 +00:00
Andrew M. Kuchling b2ceb3ad9e #4532: fixes to make 3.x compile on QNX 6.3.2 (reported by Matt Kraai) 2010-02-22 23:26:10 +00:00
Antoine Pitrou dc8c2adad6 Poor PLAN9, it isn't supported 2010-02-22 19:41:37 +00:00
Eric Smith 68af50ba39 Issue #5988: Delete deprecated functions PyOS_ascii_formatd, PyOS_ascii_strtod, and PyOS_ascii_atof. 2010-02-22 14:58:30 +00:00
Benjamin Peterson f8b60b20a5 fix comment 2010-02-11 02:31:04 +00:00
Eric Smith f7bb57875a Merged revisions 77763 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77763 | eric.smith | 2010-01-26 19:28:29 -0500 (Tue, 26 Jan 2010) | 1 line

  Issue #7766: Change sys.getwindowsversion() return value to a named tuple and add the additional members returned in an OSVERSIONINFOEX structure. The new members are service_pack_major, service_pack_minor, suite_mask, and product_type.
........
2010-01-27 00:44:57 +00:00
Mark Dickinson 95a3633c96 Merged revisions 77722 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77722 | mark.dickinson | 2010-01-24 10:16:29 +0000 (Sun, 24 Jan 2010) | 23 lines

  Merged revisions 77691,77698,77713-77714 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77691 | mark.dickinson | 2010-01-22 16:18:09 +0000 (Fri, 22 Jan 2010) | 1 line

    Correct typo in comment.
  ........
    r77698 | mark.dickinson | 2010-01-22 17:04:07 +0000 (Fri, 22 Jan 2010) | 3 lines

    Issue #7743:  Fix a potential incorrect rounding bug in dtoa.c (2nd bug
    in issue 7743).
  ........
    r77713 | mark.dickinson | 2010-01-23 20:48:56 +0000 (Sat, 23 Jan 2010) | 3 lines

    Issue #7743:  Add checks for zero inputs to the lshift and mult functions;
    this fixes the first bug described in issue #7743.
  ........
    r77714 | mark.dickinson | 2010-01-23 21:25:53 +0000 (Sat, 23 Jan 2010) | 1 line

    dtoa.c fix from upstream that fixes incorrectly rounded results for certain subnormals that are also halfway cases.
  ........
................
2010-01-24 10:16:59 +00:00
Mark Dickinson f41d29a8eb Merged revisions 77691,77698,77713-77714 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77691 | mark.dickinson | 2010-01-22 16:18:09 +0000 (Fri, 22 Jan 2010) | 1 line

  Correct typo in comment.
........
  r77698 | mark.dickinson | 2010-01-22 17:04:07 +0000 (Fri, 22 Jan 2010) | 3 lines

  Issue #7743:  Fix a potential incorrect rounding bug in dtoa.c (2nd bug
  in issue 7743).
........
  r77713 | mark.dickinson | 2010-01-23 20:48:56 +0000 (Sat, 23 Jan 2010) | 3 lines

  Issue #7743:  Add checks for zero inputs to the lshift and mult functions;
  this fixes the first bug described in issue #7743.
........
  r77714 | mark.dickinson | 2010-01-23 21:25:53 +0000 (Sat, 23 Jan 2010) | 1 line

  dtoa.c fix from upstream that fixes incorrectly rounded results for certain subnormals that are also halfway cases.
........
2010-01-24 10:16:29 +00:00
Mark Dickinson e42ffae8c4 Merged revisions 77670 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77670 | mark.dickinson | 2010-01-21 19:51:08 +0000 (Thu, 21 Jan 2010) | 24 lines

  Merged revisions 77614-77616,77663 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77614 | mark.dickinson | 2010-01-20 17:36:31 +0000 (Wed, 20 Jan 2010) | 5 lines

    Various dtoa.c cleanups.  1. Despagghetify _Py_dg_strtod parsing code
    and exit points.  2. Simplify bigcomp comparison loop.  3. Don't set
    ERANGE on _Py_dg_strtod underflow (it was set inconsistently anyway).
    4. Remove unused dsign field from BCinfo struct.
  ........
    r77615 | mark.dickinson | 2010-01-20 18:02:41 +0000 (Wed, 20 Jan 2010) | 1 line

    Don't try to put a value into a NULL pointer.
  ........
    r77616 | mark.dickinson | 2010-01-20 21:23:25 +0000 (Wed, 20 Jan 2010) | 1 line

    Additional explanatory comments for _Py_dg_strtod.
  ........
    r77663 | mark.dickinson | 2010-01-21 17:02:53 +0000 (Thu, 21 Jan 2010) | 1 line

    Additional testcases for strtod.
  ........
................
2010-01-21 19:57:43 +00:00
Mark Dickinson add2823467 Merged revisions 77614-77616,77663 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77614 | mark.dickinson | 2010-01-20 17:36:31 +0000 (Wed, 20 Jan 2010) | 5 lines

  Various dtoa.c cleanups.  1. Despagghetify _Py_dg_strtod parsing code
  and exit points.  2. Simplify bigcomp comparison loop.  3. Don't set
  ERANGE on _Py_dg_strtod underflow (it was set inconsistently anyway).
  4. Remove unused dsign field from BCinfo struct.
........
  r77615 | mark.dickinson | 2010-01-20 18:02:41 +0000 (Wed, 20 Jan 2010) | 1 line

  Don't try to put a value into a NULL pointer.
........
  r77616 | mark.dickinson | 2010-01-20 21:23:25 +0000 (Wed, 20 Jan 2010) | 1 line

  Additional explanatory comments for _Py_dg_strtod.
........
  r77663 | mark.dickinson | 2010-01-21 17:02:53 +0000 (Thu, 21 Jan 2010) | 1 line

  Additional testcases for strtod.
........
2010-01-21 19:51:08 +00:00
Mark Dickinson 173a1eedac Merged revisions 77590 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77590 | mark.dickinson | 2010-01-17 21:02:55 +0000 (Sun, 17 Jan 2010) | 14 lines

  Merged revisions 77589 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77589 | mark.dickinson | 2010-01-17 20:57:56 +0000 (Sun, 17 Jan 2010) | 7 lines

    Issue #7632: When Py_USING_MEMORY_DEBUGGER is defined, disable the
    private memory allocation scheme in dtoa.c, along with a piece of code
    that caches powers of 5 for future use.  This makes it easier to
    detect dtoa.c memory leaks with Valgrind or similar tools.

    Patch by Stefan Krah.
  ........
................
2010-01-17 21:06:28 +00:00
Mark Dickinson de5080038f Merged revisions 77589 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77589 | mark.dickinson | 2010-01-17 20:57:56 +0000 (Sun, 17 Jan 2010) | 7 lines

  Issue #7632: When Py_USING_MEMORY_DEBUGGER is defined, disable the
  private memory allocation scheme in dtoa.c, along with a piece of code
  that caches powers of 5 for future use.  This makes it easier to
  detect dtoa.c memory leaks with Valgrind or similar tools.

  Patch by Stefan Krah.
........
2010-01-17 21:02:55 +00:00
Mark Dickinson a3ba4a15ec Merged revisions 77579 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77579 | mark.dickinson | 2010-01-17 14:39:12 +0000 (Sun, 17 Jan 2010) | 9 lines

  Merged revisions 77578 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77578 | mark.dickinson | 2010-01-17 13:37:57 +0000 (Sun, 17 Jan 2010) | 2 lines

    Issue #7632: Fix a memory leak in _Py_dg_strtod.
  ........
................
2010-01-17 14:41:03 +00:00
Mark Dickinson c4f1868e88 Merged revisions 77578 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77578 | mark.dickinson | 2010-01-17 13:37:57 +0000 (Sun, 17 Jan 2010) | 2 lines

  Issue #7632: Fix a memory leak in _Py_dg_strtod.
........
2010-01-17 14:39:12 +00:00
Antoine Pitrou b7fbcd396f Issue #6690: Optimize the bytecode for expressions such as `x in {1, 2, 3}`,
where the right hand operand is a set of constants, by turning the set into
a frozenset and pre-building it as a constant.  The comparison operation
is made against the constant instead of building a new set each time it is
executed (a similar optimization already existed which turned a list of
constants into a pre-built tuple).  Patch and additional tests by Dave
Malcolm.
2010-01-16 18:37:38 +00:00
Mark Dickinson 11f657843f Merged revisions 77535 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77535 | mark.dickinson | 2010-01-16 18:10:25 +0000 (Sat, 16 Jan 2010) | 21 lines

  Merged revisions 77519,77530,77533 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77519 | mark.dickinson | 2010-01-16 10:44:00 +0000 (Sat, 16 Jan 2010) | 5 lines

    Issue #7632: Fix a serious wrong output bug for string -> float conversion.
    Also remove some now unused variables, and add comments clarifying the
    possible outputs of the parsing section of _Py_dg_strtod.  Thanks
    Eric Smith for reviewing.
  ........
    r77530 | mark.dickinson | 2010-01-16 17:57:49 +0000 (Sat, 16 Jan 2010) | 3 lines

    Issue #7632: Fix one more case of incorrect rounding for str -> float
    conversion (see bug 5 in the issue tracker).
  ........
    r77533 | mark.dickinson | 2010-01-16 18:06:17 +0000 (Sat, 16 Jan 2010) | 1 line

    Fix multiple uses of variable 'L' in _Py_dg_strtod, where one use requires an unsigned long and the other a signed long.  See also r77421.
  ........
................
2010-01-16 18:12:46 +00:00
Mark Dickinson 45b6365974 Merged revisions 77519,77530,77533 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77519 | mark.dickinson | 2010-01-16 10:44:00 +0000 (Sat, 16 Jan 2010) | 5 lines

  Issue #7632: Fix a serious wrong output bug for string -> float conversion.
  Also remove some now unused variables, and add comments clarifying the
  possible outputs of the parsing section of _Py_dg_strtod.  Thanks
  Eric Smith for reviewing.
........
  r77530 | mark.dickinson | 2010-01-16 17:57:49 +0000 (Sat, 16 Jan 2010) | 3 lines

  Issue #7632: Fix one more case of incorrect rounding for str -> float
  conversion (see bug 5 in the issue tracker).
........
  r77533 | mark.dickinson | 2010-01-16 18:06:17 +0000 (Sat, 16 Jan 2010) | 1 line

  Fix multiple uses of variable 'L' in _Py_dg_strtod, where one use requires an unsigned long and the other a signed long.  See also r77421.
........
2010-01-16 18:10:25 +00:00
Mark Dickinson 9000c1614d Merged revisions 77494 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77494 | mark.dickinson | 2010-01-14 15:37:49 +0000 (Thu, 14 Jan 2010) | 41 lines

  Merged revisions 77477-77478,77481-77483,77490-77493 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77477 | mark.dickinson | 2010-01-13 18:21:53 +0000 (Wed, 13 Jan 2010) | 1 line

    Add comments explaining the role of the bigcomp function in dtoa.c.
  ........
    r77478 | mark.dickinson | 2010-01-13 19:02:37 +0000 (Wed, 13 Jan 2010) | 1 line

    Clarify that sulp expects a nonnegative input, but that +0.0 is fine.
  ........
    r77481 | mark.dickinson | 2010-01-13 20:55:03 +0000 (Wed, 13 Jan 2010) | 1 line

    Simplify and annotate the bigcomp function, removing unused special cases.
  ........
    r77482 | mark.dickinson | 2010-01-13 22:15:53 +0000 (Wed, 13 Jan 2010) | 1 line

    Fix buggy comparison:  LHS of comparison was being treated as unsigned.
  ........
    r77483 | mark.dickinson | 2010-01-13 22:20:10 +0000 (Wed, 13 Jan 2010) | 1 line

    More dtoa.c cleanup;  remove the need for bc.dplen, bc.dp0 and bc.dp1.
  ........
    r77490 | mark.dickinson | 2010-01-14 13:02:36 +0000 (Thu, 14 Jan 2010) | 1 line

    Fix off-by-one error introduced in r77483.  I have a test for this, but it currently fails due to a different dtoa.c bug;  I'll add the test once that bug is fixed.
  ........
    r77491 | mark.dickinson | 2010-01-14 13:14:49 +0000 (Thu, 14 Jan 2010) | 1 line

    Issue 7632: fix a dtoa.c bug (bug 6) causing incorrect rounding.  Tests to follow.
  ........
    r77492 | mark.dickinson | 2010-01-14 14:40:20 +0000 (Thu, 14 Jan 2010) | 1 line

    Issue 7632:  fix incorrect rounding for long input strings with values very close to a power of 2.  (See Bug 4 in the tracker discussion.)
  ........
    r77493 | mark.dickinson | 2010-01-14 15:22:33 +0000 (Thu, 14 Jan 2010) | 1 line

    Issue #7632:  add tests for bugs fixed so far.
  ........
................
2010-01-14 15:43:57 +00:00
Mark Dickinson 853c3bbc4c Merged revisions 77477-77478,77481-77483,77490-77493 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77477 | mark.dickinson | 2010-01-13 18:21:53 +0000 (Wed, 13 Jan 2010) | 1 line

  Add comments explaining the role of the bigcomp function in dtoa.c.
........
  r77478 | mark.dickinson | 2010-01-13 19:02:37 +0000 (Wed, 13 Jan 2010) | 1 line

  Clarify that sulp expects a nonnegative input, but that +0.0 is fine.
........
  r77481 | mark.dickinson | 2010-01-13 20:55:03 +0000 (Wed, 13 Jan 2010) | 1 line

  Simplify and annotate the bigcomp function, removing unused special cases.
........
  r77482 | mark.dickinson | 2010-01-13 22:15:53 +0000 (Wed, 13 Jan 2010) | 1 line

  Fix buggy comparison:  LHS of comparison was being treated as unsigned.
........
  r77483 | mark.dickinson | 2010-01-13 22:20:10 +0000 (Wed, 13 Jan 2010) | 1 line

  More dtoa.c cleanup;  remove the need for bc.dplen, bc.dp0 and bc.dp1.
........
  r77490 | mark.dickinson | 2010-01-14 13:02:36 +0000 (Thu, 14 Jan 2010) | 1 line

  Fix off-by-one error introduced in r77483.  I have a test for this, but it currently fails due to a different dtoa.c bug;  I'll add the test once that bug is fixed.
........
  r77491 | mark.dickinson | 2010-01-14 13:14:49 +0000 (Thu, 14 Jan 2010) | 1 line

  Issue 7632: fix a dtoa.c bug (bug 6) causing incorrect rounding.  Tests to follow.
........
  r77492 | mark.dickinson | 2010-01-14 14:40:20 +0000 (Thu, 14 Jan 2010) | 1 line

  Issue 7632:  fix incorrect rounding for long input strings with values very close to a power of 2.  (See Bug 4 in the tracker discussion.)
........
  r77493 | mark.dickinson | 2010-01-14 15:22:33 +0000 (Thu, 14 Jan 2010) | 1 line

  Issue #7632:  add tests for bugs fixed so far.
........
2010-01-14 15:37:49 +00:00
Mark Dickinson 466725136d Merged revisions 77452 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77452 | mark.dickinson | 2010-01-12 23:04:19 +0000 (Tue, 12 Jan 2010) | 23 lines

  Merged revisions 77410,77421,77450-77451 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77410 | mark.dickinson | 2010-01-10 13:06:31 +0000 (Sun, 10 Jan 2010) | 1 line

    Remove unused BCinfo fields and an unused macro.
  ........
    r77421 | mark.dickinson | 2010-01-11 17:15:13 +0000 (Mon, 11 Jan 2010) | 1 line

    Change a variable type to avoid signed overflow; replace repeated '19999' constant by a define.
  ........
    r77450 | mark.dickinson | 2010-01-12 22:23:56 +0000 (Tue, 12 Jan 2010) | 4 lines

    Issue #7632: Fix a problem with _Py_dg_strtod that could lead to
    crashes in debug builds, for certain long numeric strings
    corresponding to subnormal values.
  ........
    r77451 | mark.dickinson | 2010-01-12 22:55:51 +0000 (Tue, 12 Jan 2010) | 2 lines

    Issue #7632:  Fix a bug in dtoa.c that could lead to incorrectly-rounded results.
  ........
................
2010-01-12 23:09:26 +00:00
Mark Dickinson 81612e8778 Merged revisions 77410,77421,77450-77451 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77410 | mark.dickinson | 2010-01-10 13:06:31 +0000 (Sun, 10 Jan 2010) | 1 line

  Remove unused BCinfo fields and an unused macro.
........
  r77421 | mark.dickinson | 2010-01-11 17:15:13 +0000 (Mon, 11 Jan 2010) | 1 line

  Change a variable type to avoid signed overflow; replace repeated '19999' constant by a define.
........
  r77450 | mark.dickinson | 2010-01-12 22:23:56 +0000 (Tue, 12 Jan 2010) | 4 lines

  Issue #7632: Fix a problem with _Py_dg_strtod that could lead to
  crashes in debug builds, for certain long numeric strings
  corresponding to subnormal values.
........
  r77451 | mark.dickinson | 2010-01-12 22:55:51 +0000 (Tue, 12 Jan 2010) | 2 lines

  Issue #7632:  Fix a bug in dtoa.c that could lead to incorrectly-rounded results.
........
2010-01-12 23:04:19 +00:00
Mark Dickinson 2505f1ee6c Merged revisions 77304 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77304 | mark.dickinson | 2010-01-04 21:33:31 +0000 (Mon, 04 Jan 2010) | 9 lines

  Merged revisions 77302 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77302 | mark.dickinson | 2010-01-04 21:32:02 +0000 (Mon, 04 Jan 2010) | 1 line

    Fix typo in comment.
  ........
................
2010-01-04 21:34:08 +00:00
Mark Dickinson 180e4cd54d Merged revisions 77302 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77302 | mark.dickinson | 2010-01-04 21:32:02 +0000 (Mon, 04 Jan 2010) | 1 line

  Fix typo in comment.
........
2010-01-04 21:33:31 +00:00
Mark Dickinson de60401909 Merged revisions 77218 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77218 | mark.dickinson | 2010-01-01 17:27:30 +0000 (Fri, 01 Jan 2010) | 5 lines

  Issue #5080: turn the DeprecationWarning from float arguments passed
  to integer PyArg_Parse* format codes into a TypeError.  Add a
  DeprecationWarning for floats passed with the 'L' format code, which
  didn't previously have a warning.
........
2010-01-01 19:27:32 +00:00
Ezio Melotti 370fe530c8 Merged revisions 77206-77207 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77206 | benjamin.peterson | 2010-01-01 06:47:54 +0200 (Fri, 01 Jan 2010) | 9 lines

  Merged revisions 77203 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77203 | benjamin.peterson | 2009-12-31 22:00:55 -0600 (Thu, 31 Dec 2009) | 1 line

    update copyright year
  ........
................
  r77207 | benjamin.peterson | 2010-01-01 06:49:25 +0200 (Fri, 01 Jan 2010) | 9 lines

  Merged revisions 77204 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77204 | ezio.melotti | 2009-12-31 22:16:42 -0600 (Thu, 31 Dec 2009) | 1 line

    more copyright year updates
  ........
................
2010-01-01 04:55:33 +00:00
Benjamin Peterson f8a970c02a Merged revisions 77203 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77203 | benjamin.peterson | 2009-12-31 22:00:55 -0600 (Thu, 31 Dec 2009) | 1 line

  update copyright year
........
2010-01-01 04:47:54 +00:00
Benjamin Peterson 533849a27a Merged revisions 77161 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r77161 | benjamin.peterson | 2009-12-30 13:44:54 -0600 (Wed, 30 Dec 2009) | 12 lines

  Merged revisions 77157 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r77157 | benjamin.peterson | 2009-12-30 13:34:10 -0600 (Wed, 30 Dec 2009) | 5 lines

    check if the attribute is set before deleting it with T_OBJECT_EX (fixes #7604)

    Also, add a note to the docs about the better behavior of T_OBJECT_EX as
    compared to T_OBJECT.
  ........
................
2009-12-30 19:47:05 +00:00
Benjamin Peterson d12362a828 Merged revisions 77157 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77157 | benjamin.peterson | 2009-12-30 13:34:10 -0600 (Wed, 30 Dec 2009) | 5 lines

  check if the attribute is set before deleting it with T_OBJECT_EX (fixes #7604)

  Also, add a note to the docs about the better behavior of T_OBJECT_EX as
  compared to T_OBJECT.
........
2009-12-30 19:44:54 +00:00
Georg Brandl 1e28a27f84 Merged revisions 77088 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r77088 | georg.brandl | 2009-12-28 09:34:58 +0100 (Mo, 28 Dez 2009) | 1 line

  #7033: add new API function PyErr_NewExceptionWithDoc, for easily giving new exceptions a docstring.
........
2009-12-28 08:41:01 +00:00
Mark Dickinson f371859a4f Merged revisions 76978 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r76978 | mark.dickinson | 2009-12-21 15:22:00 +0000 (Mon, 21 Dec 2009) | 3 lines

  Issue #7518:  Move substitute definitions of C99 math functions from
  pymath.c to Modules/_math.c.
........
2009-12-21 15:27:41 +00:00
Mark Dickinson 188aace8d8 Merged revisions 76902 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r76902 | mark.dickinson | 2009-12-19 21:19:35 +0000 (Sat, 19 Dec 2009) | 1 line

  Fix typo (reported by terlop on IRC)
........
2009-12-19 21:20:55 +00:00
Mark Dickinson 480e8e38a0 Fix typo (reported by terlop on IRC) 2009-12-19 21:19:35 +00:00
Benjamin Peterson fc431270ac Merged revisions 76776 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r76776 | benjamin.peterson | 2009-12-12 19:23:39 -0600 (Sat, 12 Dec 2009) | 25 lines

  Merged revisions 76534,76538,76628,76701,76774 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r76534 | martin.v.loewis | 2009-11-26 02:42:05 -0600 (Thu, 26 Nov 2009) | 2 lines

    Fix typo.
  ........
    r76538 | georg.brandl | 2009-11-26 14:48:25 -0600 (Thu, 26 Nov 2009) | 1 line

    #7400: typo.
  ........
    r76628 | andrew.kuchling | 2009-12-02 08:27:11 -0600 (Wed, 02 Dec 2009) | 1 line

    Markup fixes
  ........
    r76701 | andrew.kuchling | 2009-12-07 20:37:05 -0600 (Mon, 07 Dec 2009) | 1 line

    Typo fix; grammar fix
  ........
    r76774 | benjamin.peterson | 2009-12-12 18:54:15 -0600 (Sat, 12 Dec 2009) | 1 line

    account for PyObject_IsInstance's new ability to fail
  ........
................
2009-12-13 01:29:00 +00:00
Benjamin Peterson 0496c9ee0a regenerate Python-ast.c 2009-12-13 01:24:58 +00:00
Benjamin Peterson 97dd987ae2 Merged revisions 76534,76538,76628,76701,76774 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r76534 | martin.v.loewis | 2009-11-26 02:42:05 -0600 (Thu, 26 Nov 2009) | 2 lines

  Fix typo.
........
  r76538 | georg.brandl | 2009-11-26 14:48:25 -0600 (Thu, 26 Nov 2009) | 1 line

  #7400: typo.
........
  r76628 | andrew.kuchling | 2009-12-02 08:27:11 -0600 (Wed, 02 Dec 2009) | 1 line

  Markup fixes
........
  r76701 | andrew.kuchling | 2009-12-07 20:37:05 -0600 (Mon, 07 Dec 2009) | 1 line

  Typo fix; grammar fix
........
  r76774 | benjamin.peterson | 2009-12-12 18:54:15 -0600 (Sat, 12 Dec 2009) | 1 line

  account for PyObject_IsInstance's new ability to fail
........
2009-12-13 01:23:39 +00:00
Benjamin Peterson 0f6cae0bff remove magic number bumping from the 2.x -U option #7459 2009-12-10 02:09:08 +00:00
Mark Dickinson d0ed0db574 Merged revisions 76646 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r76646 | mark.dickinson | 2009-12-03 10:59:46 +0000 (Thu, 03 Dec 2009) | 6 lines

  Issue #7414: Add missing 'case 'C'' to skipitem() in getargs.c.  This
  was causing PyArg_ParseTupleAndKeywords(args, kwargs, "|CC", ...) to
  fail with a RuntimeError.  Thanks Case Van Horsen for tracking down
  the source of this error.
........
2009-12-03 11:01:53 +00:00
Mark Dickinson f08173bb93 Issue #7414: Add missing 'case 'C'' to skipitem() in getargs.c. This
was causing PyArg_ParseTupleAndKeywords(args, kwargs, "|CC", ...) to
fail with a RuntimeError.  Thanks Case Van Horsen for tracking down
the source of this error.
2009-12-03 10:59:46 +00:00
Mark Dickinson 192ce61941 Merged revisions 76577 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r76577 | mark.dickinson | 2009-11-28 16:38:16 +0000 (Sat, 28 Nov 2009) | 12 lines

  Merged revisions 76575 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r76575 | mark.dickinson | 2009-11-28 16:32:27 +0000 (Sat, 28 Nov 2009) | 5 lines

    Issue #1678380: When distinguishing between -0.0 and 0.0 in
    compiler_add_o, use copysign instead of examining the first and last
    bytes of the double.  The latter method fails for little-endian
    ARM, OABI, where doubles are little-endian but with the words swapped.
  ........
................
2009-11-28 16:39:12 +00:00
Mark Dickinson a73ef2f979 Merged revisions 76575 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r76575 | mark.dickinson | 2009-11-28 16:32:27 +0000 (Sat, 28 Nov 2009) | 5 lines

  Issue #1678380: When distinguishing between -0.0 and 0.0 in
  compiler_add_o, use copysign instead of examining the first and last
  bytes of the double.  The latter method fails for little-endian
  ARM, OABI, where doubles are little-endian but with the words swapped.
........
2009-11-28 16:38:16 +00:00
Antoine Pitrou bcc63a86a9 Merged revisions 76573 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r76573 | antoine.pitrou | 2009-11-28 17:12:28 +0100 (sam., 28 nov. 2009) | 3 lines

  Issue #4486: When an exception has an explicit cause, do not print its implicit context too.
........
2009-11-28 16:16:09 +00:00
Antoine Pitrou 7b0d4a238f Issue #4486: When an exception has an explicit cause, do not print its implicit context too. 2009-11-28 16:12:28 +00:00
Benjamin Peterson f6489f941c Merged revisions 75264,75268,75293,75318,75391-75392,75436,75478,75971,76003,76058,76140-76141,76231,76380,76428-76429 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r75264 | andrew.kuchling | 2009-10-05 17:30:22 -0500 (Mon, 05 Oct 2009) | 1 line

  Add various items
........
  r75268 | andrew.kuchling | 2009-10-05 17:45:39 -0500 (Mon, 05 Oct 2009) | 1 line

  Remove two notes
........
  r75293 | kristjan.jonsson | 2009-10-09 09:32:19 -0500 (Fri, 09 Oct 2009) | 2 lines

  http://bugs.python.org/issue7029
  a non-default timer wasn't actually used by the individual Tests.
........
  r75318 | benjamin.peterson | 2009-10-10 16:15:58 -0500 (Sat, 10 Oct 2009) | 1 line

  remove script which uses long gone module
........
  r75391 | andrew.kuchling | 2009-10-13 10:49:33 -0500 (Tue, 13 Oct 2009) | 1 line

  Link to PEP
........
  r75392 | andrew.kuchling | 2009-10-13 11:11:49 -0500 (Tue, 13 Oct 2009) | 1 line

  Various link, textual, and markup fixes
........
  r75436 | benjamin.peterson | 2009-10-15 10:39:15 -0500 (Thu, 15 Oct 2009) | 1 line

  don't need to mess up sys.path
........
  r75478 | senthil.kumaran | 2009-10-17 20:58:45 -0500 (Sat, 17 Oct 2009) | 3 lines

  Fix a typo.
........
  r75971 | benjamin.peterson | 2009-10-30 22:56:15 -0500 (Fri, 30 Oct 2009) | 1 line

  add some checks for evaluation order with parenthesis #7210
........
  r76003 | antoine.pitrou | 2009-10-31 19:30:13 -0500 (Sat, 31 Oct 2009) | 6 lines

  Hopefully fix the buildbot problems on test_mailbox, by computing
  the maildir toc cache refresh date before actually refreshing the cache.

  (see #6896)
........
  r76058 | benjamin.peterson | 2009-11-02 10:14:19 -0600 (Mon, 02 Nov 2009) | 1 line

  grant list.index() a more informative error message #7252
........
  r76140 | nick.coghlan | 2009-11-07 02:13:55 -0600 (Sat, 07 Nov 2009) | 1 line

  Add test for runpy.run_module package execution and use something other than logging as the example of a non-executable package
........
  r76141 | nick.coghlan | 2009-11-07 02:15:01 -0600 (Sat, 07 Nov 2009) | 1 line

  Some minor cleanups to private runpy code and docstrings
........
  r76231 | benjamin.peterson | 2009-11-12 17:42:23 -0600 (Thu, 12 Nov 2009) | 1 line

  this main is much more useful
........
  r76380 | antoine.pitrou | 2009-11-18 14:20:46 -0600 (Wed, 18 Nov 2009) | 3 lines

  Mention Giampolo R's new FTP TLS support in the what's new file
........
  r76428 | benjamin.peterson | 2009-11-19 20:15:50 -0600 (Thu, 19 Nov 2009) | 1 line

  turn goto into do while loop
........
  r76429 | benjamin.peterson | 2009-11-19 20:56:43 -0600 (Thu, 19 Nov 2009) | 2 lines

  avoid doing an uneeded import in a function
........
2009-11-25 17:46:26 +00:00
Benjamin Peterson db149ac59b Merged revisions 76425 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r76425 | benjamin.peterson | 2009-11-19 19:19:41 -0600 (Thu, 19 Nov 2009) | 13 lines

  Merged revisions 76423-76424 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r76423 | benjamin.peterson | 2009-11-19 19:15:53 -0600 (Thu, 19 Nov 2009) | 1 line

    provide line number for lambdas
  ........
    r76424 | benjamin.peterson | 2009-11-19 19:16:58 -0600 (Thu, 19 Nov 2009) | 1 line

    genexps have linenos
  ........
................
2009-11-20 01:21:35 +00:00
Benjamin Peterson f3ebc1f930 Merged revisions 76423-76424 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r76423 | benjamin.peterson | 2009-11-19 19:15:53 -0600 (Thu, 19 Nov 2009) | 1 line

  provide line number for lambdas
........
  r76424 | benjamin.peterson | 2009-11-19 19:16:58 -0600 (Thu, 19 Nov 2009) | 1 line

  genexps have linenos
........
2009-11-20 01:19:41 +00:00
Antoine Pitrou a1d23326b1 Try to strengthen condition-waiting under Windows.
If it doesn't work (doesn't solve erratic freezes) we'll have to resort
to tougher (Windows-only) measures.
2009-11-12 22:56:02 +00:00
Antoine Pitrou cf4cabbe2a Our condition variable emulation under Windows is imperfect, which
seems to be the cause of the buildbot hangs. Try to fix it, and add
some comments.
2009-11-11 18:11:36 +00:00
Antoine Pitrou aee355b7b5 Remove obsolete comment. 2009-11-10 22:38:52 +00:00
Antoine Pitrou 074e5ed974 Merge in the new GIL. 2009-11-10 19:50:40 +00:00
Mark Dickinson ee2dd4a4e3 Merged revisions 75984 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r75984 | mark.dickinson | 2009-10-31 10:18:44 +0000 (Sat, 31 Oct 2009) | 12 lines

  Merged revisions 75982 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r75982 | mark.dickinson | 2009-10-31 10:11:28 +0000 (Sat, 31 Oct 2009) | 5 lines

    Issue #6603: Fix --with-tsc build failures on x86-64 that resulted
    from a gcc inline assembler peculiarity. (gcc's "A" constraint
    apparently means 'rax or rdx' in 64-bit mode, not edx:eax
    or rdx:rax as one might expect.)
  ........
................
2009-10-31 10:20:38 +00:00
Mark Dickinson a25b1312c9 Merged revisions 75982 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r75982 | mark.dickinson | 2009-10-31 10:11:28 +0000 (Sat, 31 Oct 2009) | 5 lines

  Issue #6603: Fix --with-tsc build failures on x86-64 that resulted
  from a gcc inline assembler peculiarity. (gcc's "A" constraint
  apparently means 'rax or rdx' in 64-bit mode, not edx:eax
  or rdx:rax as one might expect.)
........
2009-10-31 10:18:44 +00:00
Benjamin Peterson 7dc5ac5ec6 Merged revisions 75928 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r75928 | benjamin.peterson | 2009-10-28 16:59:39 -0500 (Wed, 28 Oct 2009) | 5 lines

  in wide builds, avoid storing high unicode characters from source code with surrogates

  This is accomplished by decoding with utf-32 instead of utf-16 on all builds.
  The patch is by Adam Olsen.
........
2009-10-29 01:22:38 +00:00
Benjamin Peterson b2e796aa27 in wide builds, avoid storing high unicode characters from source code with surrogates
This is accomplished by decoding with utf-32 instead of utf-16 on all builds.
The patch is by Adam Olsen.
2009-10-28 21:59:39 +00:00
Georg Brandl 628e6f908e Merged revisions 75797 via svnmerge from
svn+ssh://svn.python.org/python/branches/py3k

................
  r75797 | georg.brandl | 2009-10-27 16:28:25 +0100 (Di, 27 Okt 2009) | 129 lines

  Merged revisions 75365,75394,75402-75403,75418,75459,75484,75592-75596,75600,75602-75607,75610-75613,75616-75617,75623,75627,75640,75647,75696,75795 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r75365 | georg.brandl | 2009-10-11 22:16:16 +0200 (So, 11 Okt 2009) | 1 line

    Fix broken links found by "make linkcheck".  scipy.org seems to be done right now, so I could not verify links going there.
  ........
    r75394 | georg.brandl | 2009-10-13 20:10:59 +0200 (Di, 13 Okt 2009) | 1 line

    Fix markup.
  ........
    r75402 | georg.brandl | 2009-10-14 17:51:48 +0200 (Mi, 14 Okt 2009) | 1 line

    #7125: fix typo.
  ........
    r75403 | georg.brandl | 2009-10-14 17:57:46 +0200 (Mi, 14 Okt 2009) | 1 line

    #7126: os.environ changes *do* take effect in subprocesses started with os.system().
  ........
    r75418 | georg.brandl | 2009-10-14 20:48:32 +0200 (Mi, 14 Okt 2009) | 1 line

    #7116: str.join() takes an iterable.
  ........
    r75459 | georg.brandl | 2009-10-17 10:57:43 +0200 (Sa, 17 Okt 2009) | 1 line

    Fix refleaks in _ctypes PyCSimpleType_New, which fixes the refleak seen in test___all__.
  ........
    r75484 | georg.brandl | 2009-10-18 09:58:12 +0200 (So, 18 Okt 2009) | 1 line

    Fix missing word.
  ........
    r75592 | georg.brandl | 2009-10-22 09:05:48 +0200 (Do, 22 Okt 2009) | 1 line

    Fix punctuation.
  ........
    r75593 | georg.brandl | 2009-10-22 09:06:49 +0200 (Do, 22 Okt 2009) | 1 line

    Revert unintended change.
  ........
    r75594 | georg.brandl | 2009-10-22 09:56:02 +0200 (Do, 22 Okt 2009) | 1 line

    Fix markup.
  ........
    r75595 | georg.brandl | 2009-10-22 09:56:56 +0200 (Do, 22 Okt 2009) | 1 line

    Fix duplicate target.
  ........
    r75596 | georg.brandl | 2009-10-22 10:05:04 +0200 (Do, 22 Okt 2009) | 1 line

    Add a new directive marking up implementation details and start using it.
  ........
    r75600 | georg.brandl | 2009-10-22 13:01:46 +0200 (Do, 22 Okt 2009) | 1 line

    Make it more robust.
  ........
    r75602 | georg.brandl | 2009-10-22 13:28:06 +0200 (Do, 22 Okt 2009) | 1 line

    Document new directive.
  ........
    r75603 | georg.brandl | 2009-10-22 13:28:23 +0200 (Do, 22 Okt 2009) | 1 line

    Allow short form with text as argument.
  ........
    r75604 | georg.brandl | 2009-10-22 13:36:50 +0200 (Do, 22 Okt 2009) | 1 line

    Fix stylesheet for multi-paragraph impl-details.
  ........
    r75605 | georg.brandl | 2009-10-22 13:48:10 +0200 (Do, 22 Okt 2009) | 1 line

    Use "impl-detail" directive where applicable.
  ........
    r75606 | georg.brandl | 2009-10-22 17:00:06 +0200 (Do, 22 Okt 2009) | 1 line

    #6324: membership test tries iteration via __iter__.
  ........
    r75607 | georg.brandl | 2009-10-22 17:04:09 +0200 (Do, 22 Okt 2009) | 1 line

    #7088: document new functions in signal as Unix-only.
  ........
    r75610 | georg.brandl | 2009-10-22 17:27:24 +0200 (Do, 22 Okt 2009) | 1 line

    Reorder __slots__ fine print and add a clarification.
  ........
    r75611 | georg.brandl | 2009-10-22 17:42:32 +0200 (Do, 22 Okt 2009) | 1 line

    #7035: improve docs of the various <method>_errors() functions, and give them docstrings.
  ........
    r75612 | georg.brandl | 2009-10-22 17:52:15 +0200 (Do, 22 Okt 2009) | 1 line

    #7156: document curses as Unix-only.
  ........
    r75613 | georg.brandl | 2009-10-22 17:54:35 +0200 (Do, 22 Okt 2009) | 1 line

    #6977: getopt does not support optional option arguments.
  ........
    r75616 | georg.brandl | 2009-10-22 18:17:05 +0200 (Do, 22 Okt 2009) | 1 line

    Add proper references.
  ........
    r75617 | georg.brandl | 2009-10-22 18:20:55 +0200 (Do, 22 Okt 2009) | 1 line

    Make printout margin important.
  ........
    r75623 | georg.brandl | 2009-10-23 10:14:44 +0200 (Fr, 23 Okt 2009) | 1 line

    #7188: fix optionxform() docs.
  ........
    r75627 | fred.drake | 2009-10-23 15:04:51 +0200 (Fr, 23 Okt 2009) | 2 lines

    add further note about what's passed to optionxform
  ........
    r75640 | neil.schemenauer | 2009-10-23 21:58:17 +0200 (Fr, 23 Okt 2009) | 2 lines

    Improve some docstrings in the 'warnings' module.
  ........
    r75647 | georg.brandl | 2009-10-24 12:04:19 +0200 (Sa, 24 Okt 2009) | 1 line

    Fix markup.
  ........
    r75696 | georg.brandl | 2009-10-25 21:25:43 +0100 (So, 25 Okt 2009) | 1 line

    Fix a demo.
  ........
    r75795 | georg.brandl | 2009-10-27 16:10:22 +0100 (Di, 27 Okt 2009) | 1 line

    Fix a strange mis-edit.
  ........
................
2009-10-27 20:24:45 +00:00
Mark Dickinson b42dab5452 Merged revisions 75441 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r75441 | mark.dickinson | 2009-10-15 20:55:18 +0100 (Thu, 15 Oct 2009) | 9 lines

  Merged revisions 75440 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r75440 | mark.dickinson | 2009-10-15 18:45:39 +0100 (Thu, 15 Oct 2009) | 1 line

    Allow core Python build to succeed under WITHOUT_COMPLEX.  The module build stage still fails.
  ........
................
2009-10-27 17:31:26 +00:00
Georg Brandl 495f7b5adb Merged revisions 75365,75394,75402-75403,75418,75459,75484,75592-75596,75600,75602-75607,75610-75613,75616-75617,75623,75627,75640,75647,75696,75795 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r75365 | georg.brandl | 2009-10-11 22:16:16 +0200 (So, 11 Okt 2009) | 1 line

  Fix broken links found by "make linkcheck".  scipy.org seems to be done right now, so I could not verify links going there.
........
  r75394 | georg.brandl | 2009-10-13 20:10:59 +0200 (Di, 13 Okt 2009) | 1 line

  Fix markup.
........
  r75402 | georg.brandl | 2009-10-14 17:51:48 +0200 (Mi, 14 Okt 2009) | 1 line

  #7125: fix typo.
........
  r75403 | georg.brandl | 2009-10-14 17:57:46 +0200 (Mi, 14 Okt 2009) | 1 line

  #7126: os.environ changes *do* take effect in subprocesses started with os.system().
........
  r75418 | georg.brandl | 2009-10-14 20:48:32 +0200 (Mi, 14 Okt 2009) | 1 line

  #7116: str.join() takes an iterable.
........
  r75459 | georg.brandl | 2009-10-17 10:57:43 +0200 (Sa, 17 Okt 2009) | 1 line

  Fix refleaks in _ctypes PyCSimpleType_New, which fixes the refleak seen in test___all__.
........
  r75484 | georg.brandl | 2009-10-18 09:58:12 +0200 (So, 18 Okt 2009) | 1 line

  Fix missing word.
........
  r75592 | georg.brandl | 2009-10-22 09:05:48 +0200 (Do, 22 Okt 2009) | 1 line

  Fix punctuation.
........
  r75593 | georg.brandl | 2009-10-22 09:06:49 +0200 (Do, 22 Okt 2009) | 1 line

  Revert unintended change.
........
  r75594 | georg.brandl | 2009-10-22 09:56:02 +0200 (Do, 22 Okt 2009) | 1 line

  Fix markup.
........
  r75595 | georg.brandl | 2009-10-22 09:56:56 +0200 (Do, 22 Okt 2009) | 1 line

  Fix duplicate target.
........
  r75596 | georg.brandl | 2009-10-22 10:05:04 +0200 (Do, 22 Okt 2009) | 1 line

  Add a new directive marking up implementation details and start using it.
........
  r75600 | georg.brandl | 2009-10-22 13:01:46 +0200 (Do, 22 Okt 2009) | 1 line

  Make it more robust.
........
  r75602 | georg.brandl | 2009-10-22 13:28:06 +0200 (Do, 22 Okt 2009) | 1 line

  Document new directive.
........
  r75603 | georg.brandl | 2009-10-22 13:28:23 +0200 (Do, 22 Okt 2009) | 1 line

  Allow short form with text as argument.
........
  r75604 | georg.brandl | 2009-10-22 13:36:50 +0200 (Do, 22 Okt 2009) | 1 line

  Fix stylesheet for multi-paragraph impl-details.
........
  r75605 | georg.brandl | 2009-10-22 13:48:10 +0200 (Do, 22 Okt 2009) | 1 line

  Use "impl-detail" directive where applicable.
........
  r75606 | georg.brandl | 2009-10-22 17:00:06 +0200 (Do, 22 Okt 2009) | 1 line

  #6324: membership test tries iteration via __iter__.
........
  r75607 | georg.brandl | 2009-10-22 17:04:09 +0200 (Do, 22 Okt 2009) | 1 line

  #7088: document new functions in signal as Unix-only.
........
  r75610 | georg.brandl | 2009-10-22 17:27:24 +0200 (Do, 22 Okt 2009) | 1 line

  Reorder __slots__ fine print and add a clarification.
........
  r75611 | georg.brandl | 2009-10-22 17:42:32 +0200 (Do, 22 Okt 2009) | 1 line

  #7035: improve docs of the various <method>_errors() functions, and give them docstrings.
........
  r75612 | georg.brandl | 2009-10-22 17:52:15 +0200 (Do, 22 Okt 2009) | 1 line

  #7156: document curses as Unix-only.
........
  r75613 | georg.brandl | 2009-10-22 17:54:35 +0200 (Do, 22 Okt 2009) | 1 line

  #6977: getopt does not support optional option arguments.
........
  r75616 | georg.brandl | 2009-10-22 18:17:05 +0200 (Do, 22 Okt 2009) | 1 line

  Add proper references.
........
  r75617 | georg.brandl | 2009-10-22 18:20:55 +0200 (Do, 22 Okt 2009) | 1 line

  Make printout margin important.
........
  r75623 | georg.brandl | 2009-10-23 10:14:44 +0200 (Fr, 23 Okt 2009) | 1 line

  #7188: fix optionxform() docs.
........
  r75627 | fred.drake | 2009-10-23 15:04:51 +0200 (Fr, 23 Okt 2009) | 2 lines

  add further note about what's passed to optionxform
........
  r75640 | neil.schemenauer | 2009-10-23 21:58:17 +0200 (Fr, 23 Okt 2009) | 2 lines

  Improve some docstrings in the 'warnings' module.
........
  r75647 | georg.brandl | 2009-10-24 12:04:19 +0200 (Sa, 24 Okt 2009) | 1 line

  Fix markup.
........
  r75696 | georg.brandl | 2009-10-25 21:25:43 +0100 (So, 25 Okt 2009) | 1 line

  Fix a demo.
........
  r75795 | georg.brandl | 2009-10-27 16:10:22 +0100 (Di, 27 Okt 2009) | 1 line

  Fix a strange mis-edit.
........
2009-10-27 15:28:25 +00:00
Mark Dickinson 3b38df24df Move some comments to more appropriate places 2009-10-26 14:36:29 +00:00
Mark Dickinson 9acadc54e0 Merged revisions 75714 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r75714 | mark.dickinson | 2009-10-26 14:18:44 +0000 (Mon, 26 Oct 2009) | 1 line

  Warn against replacing PyNumber_Add with PyNumber_InPlaceAdd in sum
........
2009-10-26 14:19:42 +00:00
Antoine Pitrou 2a9c2bb0fd Disable support for Irix threads 2009-10-24 20:43:49 +00:00
Antoine Pitrou db6c567a72 Disable GNU pth support 2009-10-24 20:35:52 +00:00
Antoine Pitrou 1b8c783408 Disable support for SunOS LWP 2009-10-24 20:30:34 +00:00
Antoine Pitrou 86b21c190a Disable support for Mach C Threads. 2009-10-24 20:24:16 +00:00
Antoine Pitrou 6103ab1d0b Remove AtheOS support, as per PEP 11 (which claims that all code was removed in Python 3.0). 2009-10-24 20:11:21 +00:00
Raymond Hettinger af7adad51d Peephole constant folding had missed UNARY_POSITIVE. 2009-10-22 11:22:50 +00:00
Antoine Pitrou cefb316e9e Merged revisions 75571,75576-75577 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

................
  r75571 | antoine.pitrou | 2009-10-20 23:52:47 +0200 (mar., 20 oct. 2009) | 11 lines

  Merged revisions 75570 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r75570 | antoine.pitrou | 2009-10-20 23:29:37 +0200 (mar., 20 oct. 2009) | 6 lines

    Issue #1722344: threading._shutdown() is now called in Py_Finalize(), which
    fixes the problem of some exceptions being thrown at shutdown when the
    interpreter is killed. Patch by Adam Olsen.
  ........
................
  r75576 | antoine.pitrou | 2009-10-21 00:02:29 +0200 (mer., 21 oct. 2009) | 10 lines

  Merged revisions 75574 via svnmerge from
  svn+ssh://pythondev@svn.python.org/python/trunk

  ........
    r75574 | antoine.pitrou | 2009-10-20 23:59:25 +0200 (mar., 20 oct. 2009) | 4 lines

    Test wouldn't work in debug mode.
    We probably need a function in test_support to handle this.
  ........
................
  r75577 | antoine.pitrou | 2009-10-21 00:05:38 +0200 (mer., 21 oct. 2009) | 3 lines

  Another futile error in the previous commit :-(
................
2009-10-20 22:08:36 +00:00