Commit 9b12553a authored by Mark Dickinson's avatar Mark Dickinson

Merged revisions 75283 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/trunk

........
  r75283 | mark.dickinson | 2009-10-08 16:54:10 +0100 (Thu, 08 Oct 2009) | 4 lines

  Issue #7078:  _struct.__doc__ was being ignored.  Import it into struct.
  Also add description of '?' struct format character.  Thanks Gabriel
  Genellina for the patch.
........
parent 5e672d0e
from _struct import * from _struct import *
from _struct import _clearcache from _struct import _clearcache
from _struct import __doc__
...@@ -12,6 +12,8 @@ What's New in Python 2.6.5 ...@@ -12,6 +12,8 @@ What's New in Python 2.6.5
Core and Builtins Core and Builtins
----------------- -----------------
- Issue #7078: Set struct.__doc__ from _struct.__doc__.
- Issue #1722344: threading._shutdown() is now called in Py_Finalize(), which - Issue #1722344: threading._shutdown() is now called in Py_Finalize(), which
fixes the problem of some exceptions being thrown at shutdown when the fixes the problem of some exceptions being thrown at shutdown when the
interpreter is killed. Patch by Adam Olsen. interpreter is killed. Patch by Adam Olsen.
......
...@@ -2042,9 +2042,10 @@ static struct PyMethodDef module_functions[] = { ...@@ -2042,9 +2042,10 @@ static struct PyMethodDef module_functions[] = {
/* Module initialization */ /* Module initialization */
PyDoc_STRVAR(module_doc, PyDoc_STRVAR(module_doc,
"Functions to convert between Python values and C structs.\n\ "Functions to convert between Python values and C structs represented\n\
Python strings are used to hold the data representing the C struct\n\ as Python strings. It uses format strings (explained below) as compact\n\
and also as format strings to describe the layout of data in the C struct.\n\ descriptions of the lay-out of the C structs and the intended conversion\n\
to/from Python values.\n\
\n\ \n\
The optional first format char indicates byte order, size and alignment:\n\ The optional first format char indicates byte order, size and alignment:\n\
@: native order, size & alignment (default)\n\ @: native order, size & alignment (default)\n\
...@@ -2056,6 +2057,7 @@ The optional first format char indicates byte order, size and alignment:\n\ ...@@ -2056,6 +2057,7 @@ The optional first format char indicates byte order, size and alignment:\n\
The remaining chars indicate types of args and must match exactly;\n\ The remaining chars indicate types of args and must match exactly;\n\
these can be preceded by a decimal repeat count:\n\ these can be preceded by a decimal repeat count:\n\
x: pad byte (no data); c:char; b:signed byte; B:unsigned byte;\n\ x: pad byte (no data); c:char; b:signed byte; B:unsigned byte;\n\
?: _Bool (requires C99; if not available, char is used instead)\n\
h:short; H:unsigned short; i:int; I:unsigned int;\n\ h:short; H:unsigned short; i:int; I:unsigned int;\n\
l:long; L:unsigned long; f:float; d:double.\n\ l:long; L:unsigned long; f:float; d:double.\n\
Special cases (preceding decimal count indicates length):\n\ Special cases (preceding decimal count indicates length):\n\
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment