| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
return NULL in an error case was itself an error.
|
|
|
|
| |
(if any.)
|
| |
|
|
|
|
|
| |
added copy/deepcopy support to SRE (still not enabled, since it's not
covered by the test suite)
|
|
|
|
|
| |
ch is unsigned, so testing for negative values doesn't make
sense (as noticed by the OpenVMS compiler)
|
|
|
|
|
| |
sure about this one, but test #133283 now works even with the fix in
place, and so does the test suite. we'll see what comes up...
|
| |
|
|
|
|
| |
speedups for certain unicode character ranges.
|
| |
|
|
|
|
| |
tests.
|
|
|
|
|
|
| |
SIZEOF_SHORT by hand here.
Also added dynamic check that SIZEOF_SHORT is correct for the platform (in
_testcapimodule).
|
|
|
|
|
|
| |
unicodeobject.h, which forces sizeof(Py_UNICODE) == sizeof(Py_UCS4).
(this may be good enough for platforms that doesn't have a 16-bit
type. the UTF-16 codecs don't work, though)
|
|
|
|
| |
HAVE_USABLE_WCHAR_T
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
because I need to make progress and don't have time now to think about
whatever it is the new code is trying to accomplish.
|
| |
|
| |
|
|
|
|
|
| |
Contributed by Jun-ichiro "itojun" Hagino. get{addr,name}info emulation
code taken from WIDE.
|
|
|
|
|
|
| |
PyArg_ParseTuple() call.
(2.1.1 bugfix candidate.)
|
| |
|
|
|
|
| |
the need for the F_ERROR macro.
|
|
|
|
|
|
| |
Protect several more uses of constants with #ifdefs; these are necessary on
(at least) SCO OpenServer 5. Fixes a non-SF-submitted bugreport by Michael
Kent.
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
the new PyLong_{As,From}{Unsigned,}LongLong tests, so the bulk of the
code is in the new #include file testcapi_long.h, which generates
different code depending on how macros are set. This sucks, but I couldn't
think of anything that sucked less.
UNIX headache? If we still maintain dependencies by hand, someone who
knows what they're doing should teach whatever needs it that
_testcapimodule.c includes testcapi_long.h.
|
|
|
|
| |
Repaired that, and added appropriate tests for it to test_struct.py.
|
|
|
|
|
|
|
|
|
|
|
| |
Replaced PyLong_{As,From}{Unsigned,}LongLong guts with calls
to _PyLong_{As,From}ByteArray.
_testcapimodule.c:
Added strong tests of PyLong_{As,From}{Unsigned,}LongLong.
Fixes SF bug #432552 PyLong_AsLongLong() problems.
Possible bugfix candidate, but the fix relies on code added to longobject
to support the new q/Q structmodule format codes.
|
|
|
|
|
|
|
|
|
|
| |
functions. I intend to replace their guts with calls to the new
_PyLong_{As,From}ByteArray() functions, but AFAICT there's no tests for
them at all now; I also suspect PyLong_AsLongLong() isn't catching all
overflow cases, but without a std test to demonstrate that why should you
believe me <wink>.
Also added a raiseTestError() utility function.
|
|
|
|
| |
still set to python2.0 ...
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This completes the q/Q project.
longobject.c _PyLong_AsByteArray: The original code had a gross bug:
the most-significant Python digit doesn't necessarily have SHIFT
significant bits, and you really need to count how many copies of the sign
bit it has else spurious overflow errors result.
test_struct.py: This now does exhaustive std q/Q testing at, and on both
sides of, all relevant power-of-2 boundaries, both positive and negative.
NEWS: Added brief dict news while I was at it.
|
| |
|
|
|
|
| |
in native mode on platforms that don't HAVE_LONG_LONG.
|
|
|
|
|
|
| |
not just to alignment. Spotted by Guido.
Bugfix candidate.
|
|
|
|
| |
on (some versions of ?) AIX.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
native mode, and only when config #defines HAVE_LONG_LONG. Standard mode
will eventually treat them as 8-byte ints across all platforms, but that
likely requires a new set of routines in longobject.c first (while
sizeof(long) >= 4 is guaranteed by C, there's nothing in C we can rely
on x-platform to hold 8 bytes of int, so we'll have to roll our own;
I'm thinking of a simple pair of conversion functions, Python long
to/from sized vector of unsigned bytes; that may be useful for GMP
conversions too; std q/Q would call them with size fixed at 8).
test_struct.py: In addition to adding some native-mode 'q' and 'Q' tests,
got rid of unused code, and repaired a non-portable assumption about
native sizeof(short) (it isn't 2 on some Cray boxes).
libstruct.tex: In addition to adding a bit of 'q'/'Q' docs (more needed
later), removed an erroneous footnote about 'I' behavior.
|
| |
|
| |
|
|
|
|
| |
(Just a change to a comment)
|
|
|
|
| |
directives, which is the role of CPPFLAGS. Closes SF patch #414991.
|
|
|
|
| |
_PyTuple_Resize().
|
|
|
|
| |
ought to be faster.
|
|
|
|
|
|
| |
when #ifdef was needed.
This closes (reallu!) SF bug #417418.
|
| |
|
|
|
|
|
|
|
|
|
| |
*are* obsolete; three variables and the maketrans() function are not
(yet) obsolete.
Add a compensating warnings.filterwarnings() call to test_strop.py.
Add this to the NEWS.
|
|
|
|
|
|
|
|
| |
return a (C) long: PyArg_ParseTuple and Py_BuildValue may not let us get
at the size_t we really want, but C int is clearly too small for a 64-bit
box, and both the start parameter and the return value should work for
large mapped files even on 32-bit boxes. The code really needs to be
rethought from scratch (not by me, though ...).
|
| |
|
| |
|