Commit graph

456 commits

Author SHA1 Message Date
Brett Cannon
9b000e7a68 Issue #15482: Properly document the default 'level' parameter for
__import__().

To help explain why the -1 default value is typically not seen, a note
about how import statements only use values of >= 0 is also noted.
2012-08-05 20:46:25 -04:00
Victor Stinner
d1f9352bd4 (Merge 3.2) open() / TextIOWrapper doc: make it explicit than newline='\n'
doesn't translate newlines on output.
2012-08-04 01:22:07 +02:00
Victor Stinner
401e17d0f0 open() / TextIOWrapper doc: make it explicit than newline='\n' doesn't
translate newlines on output.
2012-08-04 01:18:56 +02:00
Brett Cannon
60622ed12a Minor markup tweak. 2012-07-30 19:31:00 -04:00
Brett Cannon
73df364ee6 Add a versionchanged mention to __import__ in regards to negative level values. 2012-07-30 18:35:17 -04:00
Chris Jerdonek
17fc44c9b3 Improve str() and object.__str__() documentation (issue #13538). 2012-11-20 17:31:02 -08:00
Terry Jan Reedy
dd445e8ece Merge 3.2 closes issue 13557 2012-07-08 17:52:58 -04:00
Terry Jan Reedy
83efd6cbb6 Issue #13557: Clarify effect of giving two different namespaces to exec or
execfile().
2012-07-08 17:36:14 -04:00
Victor Stinner
f86a5e8a93 Close #11022: TextIOWrapper doesn't call locale.setlocale() anymore
open() and io.TextIOWrapper are now calling locale.getpreferredencoding(False)
instead of locale.getpreferredencoding() in text mode if the encoding is not
specified. Don't change temporary the locale encoding using locale.setlocale(),
use the current locale encoding instead of the user preferred encoding.

Explain also in open() documentation that locale.getpreferredencoding(False) is
called if the encoding is not specified.
2012-06-05 13:43:22 +02:00
Charles-François Natali
b93f9fa700 Issue #12760: Add some mising documentation about the new x exclusive
creation flag to open().
2012-05-20 11:41:53 +02:00
Nick Coghlan
7fc570a51e Close #14588: added a PEP 3115 compliant dynamic type creation mechanism 2012-05-20 02:34:13 +10:00
Brett Cannon
2a082add9d Clarify that one should not use __import__() directly. Also mention
PEP 328 in explaining how 'index' works.
2012-04-14 21:58:33 -04:00
Mark Dickinson
c7ceb2bc95 merge 3.2 (#9574) 2012-03-10 16:11:49 +00:00
Mark Dickinson
328dd0d5f3 Closes #9574: Note that complex constructor doesn't allow whitespace around central operator. 2012-03-10 16:09:35 +00:00
Terry Jan Reedy
a3d1e2e342 #11633 At least 2 people prefer earlier revision. 2012-01-12 14:49:02 -05:00
Terry Jan Reedy
e247928fed Closes #11633 Clarify print buffering. 2012-01-11 14:09:49 -05:00
Georg Brandl
bc3b682923 Closes #13761: add a "flush" keyword argument to print(). 2012-01-13 19:41:25 +01:00
Terry Jan Reedy
dc41e3f23f Merge #11633 At least 2 people prefer earlier revision. 2012-01-12 14:51:14 -05:00
Terry Jan Reedy
7a825ba3c6 Merge with 3.2
#11633 Clarify print buffering (will change again if 13761 adds flush param).
2012-01-11 14:14:14 -05:00
Benjamin Peterson
878ce389a0 add introspection to range objects (closes #9896)
Patch by Daniel Urban.
2011-11-05 15:17:52 -04:00
Ross Lagerwall
59142db6d3 Issue #12797: Added custom opener parameter to builtin open() and FileIO.open(). 2011-10-31 20:34:46 +02:00
Raymond Hettinger
5d12faa5b8 Merge 2011-10-30 15:07:01 -07:00
Raymond Hettinger
6f45d18c24 Improve itertools docs with clearer examples of pure python equivalent code. 2011-10-30 15:06:14 -07:00
Ezio Melotti
963004d1d8 Fix typo. 2011-10-25 09:41:13 +03:00
Ezio Melotti
c99c85899a Remove mention of narrow/wide builds from ord/chr doc. 2011-10-25 09:32:34 +03:00
Mark Dickinson
36645681c8 Issue #13201: equality for range objects is now based on equality of the underlying sequences. Thanks Sven Marnach for the patch. 2011-10-23 19:53:01 +01:00
Ezio Melotti
f10644983e Merge with 3.2. 2011-10-19 11:06:26 +03:00
Ezio Melotti
e130a52d8a Remove duplication. 2011-10-19 10:58:56 +03:00
Antoine Pitrou
62ab10a05a Replace mentions of IOError 2011-10-12 20:10:51 +02:00
Éric Araujo
18ddf826e7 Add links from library/functions to other docs.
Suggested by Terry J. Reedy in #12298.
2011-09-01 23:10:36 +02:00
Éric Araujo
9edd9f035b Fix a few links in the table of built-in functions (#12298) 2011-09-01 23:08:55 +02:00
Éric Araujo
e8b7eb07e1 Link isinstance/issubclass to the ABC glossary entry (#12256) 2011-08-19 02:17:03 +02:00
Éric Araujo
e801aa2a1d Let the doc of __import__ link to importlib (#9254).
importlib.import_module eschews a number of issues that __import__ has.
Reviewed by Brett Cannon.  (The docstring of __import__ was already
updated in 3d490c3a019e, for #7397.)
2011-07-29 17:50:58 +02:00
Raymond Hettinger
9d3df6d508 Issue 11889: Clarify docs for enumerate. 2011-06-25 15:00:14 +02:00
Raymond Hettinger
9028928156 Forward port doc updates for builtin functions. 2011-06-01 16:17:23 -07:00
Éric Araujo
c5069e0070 Merge doc touch-ups and fixes for #9831 and #9223 from 3.1 2011-05-29 00:29:56 +02:00
Éric Araujo
f33de71514 Minor doc addition for clarity 2011-05-27 04:42:47 +02:00
Raymond Hettinger
30439b23c0 Document default fmtspec. Fix inaccurate note. Document exceptions. 2011-05-11 10:47:27 -07:00
Georg Brandl
2a39b71ecc Replace sys.maxint mention by sys.maxsize. 2010-12-28 09:16:12 +00:00
Georg Brandl
46402378ca Fix markup errors. 2010-12-04 19:06:18 +00:00
Georg Brandl
8334fd9285 Add an "optimize" parameter to compile() to control the optimization level, and provide an interface to it in py_compile, compileall and PyZipFile. 2010-12-04 10:26:46 +00:00
Georg Brandl
38e117d20a Fix punctuation. 2010-12-03 17:19:27 +00:00
Nick Coghlan
37ee850b10 Issue 2690: Add support for slicing and negative indices to range objects (includes precalculation and storage of the range length).
Refer to the tracker issue for the language moratorium implications of this change
2010-12-03 14:26:13 +00:00
Ezio Melotti
1de911592e Add callable() to the built-in functions table. 2010-11-28 04:18:54 +00:00
Antoine Pitrou
e71362d3de Issue #10518: Bring back the callable() builtin.
Approved by Guido (BDFL) and Georg (RM).
2010-11-27 22:00:11 +00:00
Georg Brandl
ab32fec83c Merged revisions 85572-85573,85606,85609-85622,85624,85626-85627,85629,85631,85633,85635-85636,85638-85639,85641-85642 via svnmerge from
svn+ssh://svn.python.org/python/branches/py3k

........
  r85572 | georg.brandl | 2010-10-16 20:51:05 +0200 (Sa, 16 Okt 2010) | 1 line

  #10122: typo fix.
........
  r85573 | georg.brandl | 2010-10-16 20:53:08 +0200 (Sa, 16 Okt 2010) | 1 line

  #10124: typo fix.
........
  r85606 | georg.brandl | 2010-10-17 08:32:59 +0200 (So, 17 Okt 2010) | 1 line

  #10058: tweak wording about exception returns.
........
  r85609 | georg.brandl | 2010-10-17 11:19:03 +0200 (So, 17 Okt 2010) | 1 line

  #8556: use less confusing mapping key in example.
........
  r85610 | georg.brandl | 2010-10-17 11:23:05 +0200 (So, 17 Okt 2010) | 1 line

  #8686: remove potentially confusing wording that does not add any value.
........
  r85611 | georg.brandl | 2010-10-17 11:33:24 +0200 (So, 17 Okt 2010) | 1 line

  #8811: small fixes to sqlite3 docs.
........
  r85612 | georg.brandl | 2010-10-17 11:37:54 +0200 (So, 17 Okt 2010) | 1 line

  #8855: add shelve security warning.
........
  r85613 | georg.brandl | 2010-10-17 11:43:35 +0200 (So, 17 Okt 2010) | 1 line

  Fix hmac docs: it takes and returns bytes, except for hexdigest().
........
  r85614 | georg.brandl | 2010-10-17 11:46:11 +0200 (So, 17 Okt 2010) | 1 line

  #8968: add actual name of token constants.
........
  r85615 | georg.brandl | 2010-10-17 12:05:13 +0200 (So, 17 Okt 2010) | 1 line

  #459007: merge info from PC/getpathp.c and using/windows.rst to document the forming of sys.path under Windows.
........
  r85616 | georg.brandl | 2010-10-17 12:07:29 +0200 (So, 17 Okt 2010) | 1 line

  Fix copy-paste error in example.
........
  r85617 | georg.brandl | 2010-10-17 12:09:06 +0200 (So, 17 Okt 2010) | 1 line

  #5212: md5 weaknesses do not affect hmac, so remove the note about that.
........
  r85618 | georg.brandl | 2010-10-17 12:14:38 +0200 (So, 17 Okt 2010) | 1 line

  #9086: correct wrong terminology about linking with pythonXY.dll.
........
  r85619 | georg.brandl | 2010-10-17 12:15:50 +0200 (So, 17 Okt 2010) | 1 line

  Make file names consistent.
........
  r85620 | georg.brandl | 2010-10-17 12:22:28 +0200 (So, 17 Okt 2010) | 1 line

  Remove second parser module example; it referred to non-readily-available example files, and this kind of discovery is much better done with the AST nowadays anyway.
........
  r85621 | georg.brandl | 2010-10-17 12:24:54 +0200 (So, 17 Okt 2010) | 1 line

  #9105: move pickle warning to a bit more prominent location.
........
  r85622 | georg.brandl | 2010-10-17 12:28:04 +0200 (So, 17 Okt 2010) | 1 line

  #9112: document error() and exit() methods of ArgumentParser.
........
  r85624 | georg.brandl | 2010-10-17 12:34:28 +0200 (So, 17 Okt 2010) | 1 line

  Some markup and style fixes in argparse docs.
........
  r85626 | georg.brandl | 2010-10-17 12:38:20 +0200 (So, 17 Okt 2010) | 1 line

  #9117: fix syntax for class definition.
........
  r85627 | georg.brandl | 2010-10-17 12:44:11 +0200 (So, 17 Okt 2010) | 1 line

  #9138: reword introduction to classes in Python.
........
  r85629 | georg.brandl | 2010-10-17 12:51:45 +0200 (So, 17 Okt 2010) | 1 line

  #5962: clarify sys.exit() vs. threads.
........
  r85631 | georg.brandl | 2010-10-17 12:53:54 +0200 (So, 17 Okt 2010) | 1 line

  Fix capitalization.
........
  r85633 | georg.brandl | 2010-10-17 12:59:41 +0200 (So, 17 Okt 2010) | 1 line

  #9204: remove mentions of removed types in the types module.
........
  r85635 | georg.brandl | 2010-10-17 13:03:22 +0200 (So, 17 Okt 2010) | 1 line

  #5121: fix claims about default values leading to segfaults.
........
  r85636 | georg.brandl | 2010-10-17 13:06:14 +0200 (So, 17 Okt 2010) | 1 line

  #9237: document sys.call_tracing().
........
  r85638 | georg.brandl | 2010-10-17 13:13:37 +0200 (So, 17 Okt 2010) | 1 line

  Port changes to pickle docs apparently lost in py3k.
........
  r85639 | georg.brandl | 2010-10-17 13:23:56 +0200 (So, 17 Okt 2010) | 1 line

  Make twisted example a bit more logical.
........
  r85641 | georg.brandl | 2010-10-17 13:29:07 +0200 (So, 17 Okt 2010) | 1 line

  Fix documentation of dis.opmap direction.
........
  r85642 | georg.brandl | 2010-10-17 13:36:28 +0200 (So, 17 Okt 2010) | 1 line

  #9730: fix example.
........
2010-11-26 08:49:15 +00:00
Ezio Melotti
3188b2082e Merged revisions 86737 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r86737 | ezio.melotti | 2010-11-25 00:02:18 +0200 (Thu, 25 Nov 2010) | 1 line

  Add NEWS entry for r86732 and fix double function in the table.
........
2010-11-24 22:04:22 +00:00
Ezio Melotti
17f9b3d289 Add NEWS entry for r86732 and fix double function in the table. 2010-11-24 22:02:18 +00:00
Ezio Melotti
42cc06ebf4 Merged revisions 86732 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r86732 | ezio.melotti | 2010-11-24 22:18:02 +0200 (Wed, 24 Nov 2010) | 1 line

  #10299: Add a table that lists all the built-in functions in functions.rst
........
2010-11-24 20:54:01 +00:00
Ezio Melotti
f21c7ed39d #10299: Add a table that lists all the built-in functions in functions.rst 2010-11-24 20:18:02 +00:00