Commit Graph

3710 Commits

Author SHA1 Message Date
Martin Panter ca56dd4767 Issue #28139: Fix messed up indentation
Also update the classmethod and staticmethod doc strings and comments to
match the RST documentation.
2016-09-17 07:54:55 +00:00
Martin Panter 440bbd0e38 Correct occurance → occurrence; extracted from patch by Georg Brandl 2016-09-08 05:22:16 +00:00
Martin Panter 6507657ddd Issue #27895: Spelling fixes (Contributed by Ville Skyttä). 2016-09-07 12:03:06 +00:00
Benjamin Peterson 89f676f30c promote some shifts to unsigned, so as not to invoke undefined behavior 2016-09-06 20:40:04 -07:00
Benjamin Peterson d4d7900307 make sure to not call memcpy with a NULL second argument 2016-09-06 17:58:25 -07:00
Mark Dickinson 02c0c0b6e7 Issue #27870: A left shift of zero by a large integer no longer attempts to allocate large amounts of memory. 2016-08-29 19:38:12 +01:00
Mark Dickinson 89446b2c91 Issue #25604: Fix bug in integer true division that could have resulted in off-by-one-ulp results in unusual cases. 2016-08-21 10:59:48 +01:00
Victor Stinner 42e9d94bc5 Fix a refleak in call_maybe()
Issue #27128. Fix a reference leak if creating the tuple to pass positional
parameters fails.
2016-08-19 17:58:54 +02:00
Victor Stinner c9921d3bdc Fix a refleak in call_method()
Issue #27128. Fix a reference leak if creating the tuple to pass positional
parameters fails.
2016-08-19 17:52:53 +02:00
Martin Panter 3d36f0f712 Spelling and grammar fixes in code comments and documentation 2016-07-28 02:37:04 +00:00
Martin Panter a850ef698e Issue #27626: Spelling fixes in docs, comments and internal names
Based on patch by Ville Skyttä.
2016-07-28 01:11:04 +00:00
Martin Panter 2a0438d2e4 Issue #27581: Don’t rely on overflow wrapping in PySequence_Tuple()
Patch by Xiang Zhang.
2016-07-25 02:30:05 +00:00
Martin Panter 0c08fe09f9 Issue #27507: Check for integer overflow in bytearray.extend()
Patch by Xiang Zhang.
2016-07-18 07:53:13 +00:00
Serhiy Storchaka 373773d5b2 Issue #27473: Fixed possible integer overflow in str, unicode and bytearray
concatenations and repetitions.  Based on patch by Xiang Zhang.
2016-07-12 15:46:57 +03:00
Martin Panter b362f75f6e Issue #25523: Correct "a" article to "an" article
This changes the main documentation, doc strings, source code comments, and a
couple error messages in the test suite. In some cases the word was removed
to fix the grammar.
2015-11-02 03:37:02 +00:00
Benjamin Peterson ee69451f34 fix refleaks in PyDict_SetItem error cases (closes #27248) 2016-07-06 23:26:32 -07:00
Serhiy Storchaka 3c9ce74c21 Issue #23908: os functions, open() and the io.FileIO constructor now reject
unicode paths with embedded null character on Windows instead of silently
truncate them.
2016-07-01 23:34:44 +03:00
Martin Panter 646b528467 Issue #22463: Backport compiler warning fixes and workarounds
* Set but unused variable in Parser/pgen.c in non-debug builds. Patch by
  Christian Heimes.
* Unused static function in Modules/readline.c. Patch by Georg Brandl.
* main_window unused in Modules/tkappinit.c. Patch by Gregory P. Smith.
* Dead assignment in Modules/_ctypes/cfield.c. Extracted from patch by Brett
  Cannon.
* Expression result unused in PyObject_INIT macro expansions. Based on
  patches by Christian Heimes.
* Load expat_config.h and therefore pyconfig.h before C stdlib headers are
  loaded. This silences pre-processor warnings including '_POSIX_C_SOURCE
  redefined'. Extracted from patch by Christian Heimes.
2016-06-21 23:58:05 +00:00
Serhiy Storchaka 1a9ee946b0 Issue #27225: Fixed a reference leak in type_new when setting __new__ fails.
Original patch by Xiang Zhang.
2016-06-05 11:06:42 +03:00
Serhiy Storchaka d37781eb2e Issue #20041: Fixed TypeError when frame.f_trace is set to None.
Patch by Xavier de Gaye.
2016-06-04 20:30:43 +03:00
Martin Panter 8d496add74 Issue #27171: Fix typos in documentation, code comments, and tests 2016-06-02 10:35:44 +00:00
Martin Panter 200a615774 Issue #27125: Remove duplicated words from documentation and comments 2016-05-30 04:04:50 +00:00
Martin Panter b44c4520d9 Issue #27125: Fix various errors like “will [be] inherited” 2016-05-29 08:13:58 +00:00
Benjamin Peterson 6ee36a5a8c Backed out changeset e7062dd9085e (#25731) 2016-05-28 14:03:41 -07:00
Martin Panter b1d867f149 Issue #27076: Doc, comment and test function name spelling fixes
Most fixes to Doc/ and Lib/ directories by Ville Skyttä.
2016-05-26 05:28:50 +00:00
Serhiy Storchaka c742dff16a Issue #27039: Fixed bytearray.remove() for values greater than 127.
Patch by Joe Jevnik.
2016-05-16 22:15:57 +03:00
Benjamin Peterson 413a8e1b1b fix indentation of comments in cellobject.c (closes #27011) 2016-05-12 23:12:21 -07:00
Martin Panter 4f23cabc16 Corrections for a/an in code comments and documentation 2016-05-08 13:45:55 +00:00
Serhiy Storchaka 816a5ff3b2 Issue #17765: weakref.ref() no longer silently ignores keyword arguments.
Patch by Georg Brandl.
2016-05-07 15:41:09 +03:00
Serhiy Storchaka 9a118f1dc3 Issue #26778: Fixed "a/an/and" typos in code comment and documentation. 2016-04-17 09:37:36 +03:00
Benjamin Peterson 414f8b937f add gc support to slice (closes #26659) 2016-04-16 14:47:12 -07:00
Martin Panter 6a8163a928 Correct “an” → “a” with “Unicode”, “user”, “UTF”, etc
This affects documentation and code comments.
2016-04-15 02:14:19 +00:00
Serhiy Storchaka 9ec6464008 Issue #26718: super.__init__ no longer leaks memory if called multiple times.
NOTE: A direct call of super.__init__ is not endorsed!
2016-04-13 15:27:33 +03:00
Serhiy Storchaka 763a61ca95 Issue #26200: Added Py_SETREF and replaced Py_XSETREF with Py_SETREF
in places where Py_DECREF was used.
2016-04-10 18:05:12 +03:00
Serhiy Storchaka 149d080871 Issue #13410: Fixed a bug in PyUnicode_Format where it failed to properly
ignore errors from a __int__() method.

Patch based on the patch for issue #15516.
2016-04-10 15:26:52 +03:00
Serhiy Storchaka bc62af1bbe Issue #22570: Renamed Py_SETREF to Py_XSETREF. 2016-04-06 09:51:18 +03:00
Serhiy Storchaka 14a7d6389f Issue #26494: Fixed crash on iterating exhausting iterators.
Affected classes are generic sequence iterators, iterators of bytearray,
list, tuple, set, frozenset, dict, OrderedDict and corresponding views.
2016-03-30 20:43:06 +03:00
Benjamin Peterson 4ddb44a1d0 properly use PyObject_CallMethod in dictview binary operations (closes #26478) 2016-03-03 22:05:36 -08:00
Serhiy Storchaka 1c496178d2 Issue #25698: Importing module if the stack is too deep no longer replaces
imported module with the empty one.
2016-02-10 10:28:06 +02:00
Benjamin Peterson b59b04dd86 fix hash member name (closes #22847) 2016-02-06 22:36:06 -08:00
Benjamin Peterson 4a0a9556fc fix debug assertion 2016-02-04 22:26:10 -08:00
Antoine Pitrou 225e7c0def Issue #22847: Improve method cache efficiency. 2014-11-15 00:56:27 +01:00
Victor Stinner 7791165fb3 code_richcompare() now uses the constants types
Issue #25843: When compiling code, don't merge constants if they are equal but
have a different types. For example, "f1, f2 = lambda: 1, lambda: 1.0" is now
correctly compiled to two different functions: f1() returns 1 (int) and f2()
returns 1.0 (int), even if 1 and 1.0 are equal.

Add a new _PyCode_ConstantKey() private function.
2016-01-22 12:33:12 +01:00
Benjamin Peterson a4acf1ff84 set tp_new from the class in the hierarchy that actually owns the descriptor (closes #25731)
Debugging by Eryk Sun.
2016-01-18 21:17:54 -08:00
Barry Warsaw 607965eb7e Comment out two tests that won't pass now after reverting the typeobject.c
change.  Also, as per further discussion, we'll just remove the regressing
code in typeobject.c
2016-01-11 14:44:59 -05:00
Barry Warsaw f65395c8c2 Issue #22995: [UPDATE] Comment out the one of the pickleability tests in
_PyObject_GetState() due to regressions observed in Cython-based projects.
2016-01-11 13:52:23 -05:00
Benjamin Peterson f30bad284b remove some copyright notices supserseded by the toplevel ones 2016-01-01 11:53:47 -06:00
Serhiy Storchaka 28f35f246b Issue #25961: Fixed compilation error and a leak in type constructor. 2015-12-31 12:03:14 +02:00
Serhiy Storchaka f9347e3b44 Issue #25961: Disallowed null characters in the type name. 2015-12-30 21:39:21 +02:00
Serhiy Storchaka b8e54dd806 Issue #22995: Instances of extension types with a state that aren't
subclasses of list or dict and haven't implemented any pickle-related
methods (__reduce__, __reduce_ex__, __getnewargs__, __getnewargs_ex__,
or __getstate__), can no longer be pickled.  Including memoryview.
2015-12-30 20:43:29 +02:00