Ezio Melotti
3c76aa6b23
Remove unused variabile "plain" in builtin_exec.
13 years ago
Barry Warsaw
82c1c781c7
- Issue #16514 : Fix regression causing a traceback when sys.path[0] is None
(actually, any non-string or non-bytes type).
13 years ago
Christian Heimes
5c1c831211
RISCOS support has been removed a long time ago. Remove last remains in sys.flags code. #16501 can be closed, too.
13 years ago
Brett Cannon
540187f719
Regen importlib.h
13 years ago
Brett Cannon
5650e4f41c
Issue #15627 : Add the compile_source() method to
importlib.abc.SourceLoader.
This provides an easy hook into the import system to allow for source
transformations, AST optimizations, etc.
13 years ago
Ezio Melotti
7c66319edc
#16306 : Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
13 years ago
Ezio Melotti
db5947f0f3
#16306 : Fix multiple error messages when unknown command line parameters where passed to the interpreter. Patch by Hieu Nguyen.
13 years ago
Brett Cannon
e4710cfced
Issue #15894 : Document why we don't worry about re-acquiring the
global import lock after forking.
13 years ago
Victor Stinner
0d92c4f667
Issue #16416 : Fix error handling in _Py_wchar2char() _Py_char2wchar() functions
13 years ago
Victor Stinner
e262377cab
Issue #16416 : OS data are now always encoded/decoded to/from
UTF-8/surrogateescape, instead of the locale encoding (which may be ASCII if no
locale environment variable is set), to avoid inconsistencies with
os.fsencode() and os.fsdecode() functions which are already using
UTF-8/surrogateescape.
13 years ago
Benjamin Peterson
2a0e226131
recompile importlib.h
13 years ago
Stefan Krah
6df5cae49a
Issue #15835 : Define PATH_MAX on HP-UX.
13 years ago
Hynek Schlawack
b271b3e188
Issue #15001 : fix segfault on "del sys.modules['__main__']"
Patch by Victor Stinner.
13 years ago
Hynek Schlawack
5c6b3e214c
Issue #15001 : fix segfault on "del sys.module['__main__']"
Patch by Victor Stinner.
13 years ago
Ezio Melotti
6c5f5210be
#5057 : the peepholer no longer optimizes subscription on unicode literals (e.g. u"foo"[0]) in order to produce compatible pyc files between narrow and wide builds.
13 years ago
Ezio Melotti
c18cc0edff
#5057 : the peepholer no longer optimizes subscription on unicode literals (e.g. u"foo"[0]) in order to produce compatible pyc files between narrow and wide builds.
13 years ago
Nick Coghlan
aab9c2b2ea
Issue #5765 : Apply a hard recursion limit in the compiler
Previously, excessive nesting in expressions would blow the
stack and segfault the interpreter. Now, a hard limit based
on the configured recursion limit and a hardcoded scaling
factor is applied.
13 years ago
Ezio Melotti
540da76115
#16336 : fix input checking in the surrogatepass error handler. Patch by Serhiy Storchaka.
13 years ago
Andrew Svetlov
76bcff27b2
Issue #7317 : Display full tracebacks when an error occurs asynchronously.
Patch by Alon Horev with update by Alexey Kachayev.
13 years ago
Andrew Svetlov
90c0eb28c5
Issue #16218 : Support non ascii characters in python launcher.
Patch by Serhiy Storchaka.
13 years ago
Benjamin Peterson
d9c8702c0f
point errors related to nonlocals and globals to the statement declaring them ( closes #10189 )
13 years ago
Benjamin Peterson
e132f527c9
check return value of _PyUnicode_AsString
13 years ago
Benjamin Peterson
42124a727d
initialize map/filter/zip in _PyBuiltin_Init rather than the catch-all function
13 years ago
Victor Stinner
76df43de30
Issue #16330 : Use surrogate-related macros
Patch written by Serhiy Storchaka.
13 years ago
Philip Jenvey
45c41494bf
bounds check for bad data (thanks amaury)
13 years ago
Nick Coghlan
557c76c136
Fix compilation on Windows
13 years ago
Nick Coghlan
eb8d627bbd
Issue #6074 : Apply an appropriate fix for importlib based imports
13 years ago
Nick Coghlan
34937ce249
Issue #6074 : Forward port Windows read-only source file fix from 2.7
13 years ago
Nick Coghlan
b48c028ca7
Issue #6074 : Restore the long-broken support for running with read-only source files on Windows
13 years ago
Christian Heimes
743e0cd6b5
Issue #16166 : Add PY_LITTLE_ENDIAN and PY_BIG_ENDIAN macros and unified
endianess detection and handling.
13 years ago
Trent Nelson
d783c8ed00
Issue #15833 : don't raise an exception if importlib can't write byte-compiled
files.
This fixes a regression introduced by 3.3. Patch by Charles-François Natali.
13 years ago
Benjamin Peterson
fe1bcb64cd
move more variable declarations to the top of blocks
13 years ago
Benjamin Peterson
f208df3618
move declaration to top of block
13 years ago
Benjamin Peterson
31a58ff1c3
ceval cleanup
- Make many variables local to the opcode; Kill u, v, w, and x.
- Force every opcode to end with DISPATCH or jump to error handling.
- Simplify error handling.
- Check error statuses in more places.
Closes #16191 .
13 years ago
Brett Cannon
6072e0bf42
Remove uses of % with str.format.
13 years ago
Brett Cannon
a6ce4fd426
Closes issue #15111 : Calling __import__ with a module specified in
fromlist which causes its own ImportError (e.g. the module tries to
import a non-existent module) should have that exception propagate.
13 years ago
Benjamin Peterson
00f86f2202
add some missing DISPATCH()
13 years ago
Chris Jerdonek
ad4b000179
Issue #14783 : Backport changes from 3.2.
13 years ago
Jesus Cea
f01d695ccd
Closes #16135 : Removal of OS/2 support
13 years ago
Jesus Cea
b48925a406
#16135 : Removal of OS/2 support (I)
13 years ago
Victor Stinner
3b635cd447
Close #15766 : Catch exceptions while raising the ImportError in imp.load_dynamic()
13 years ago
Victor Stinner
621ef3d84f
Issue #15609 : Optimize str%args for integer argument
- Use _PyLong_FormatWriter() instead of formatlong() when possible, to avoid
a temporary buffer
- Enable the fast path when width is smaller or equals to the length,
and when the precision is bigger or equals to the length
- Add unit tests!
- formatlong() uses PyUnicode_Resize() instead of _PyUnicode_FromASCII()
to resize the output string
13 years ago
Brett Cannon
8ed677db12
Add some comments.
13 years ago
Benjamin Peterson
0beb4d28d0
don't depend on __debug__ because it's baked in at freeze time (issue #16046 )
13 years ago
Benjamin Peterson
feaa54f537
don't depend on __debug__ because it's baked in at freeze time (issue #16046 )
13 years ago
Antoine Pitrou
ca8aa4acf6
Issue #15144 : Fix possible integer overflow when handling pointers as integer values, by using Py_uintptr_t instead of size_t.
Patch by Serhiy Storchaka.
13 years ago
Christian Heimes
dfaf90da9c
Cleanup 'k' when the creation of PySTEntryObject fails. ad3824a90261 used to decref 'k' in too many error cases.
14 years ago
Christian Heimes
55ad6515c9
Cleanup 'k' when the creation of PySTEntryObject fails. ad3824a90261 used to decref 'k' in too many error cases.
14 years ago
Christian Heimes
65a0141e14
Partly revert ad3824a90261 and add comment about reference ownership
14 years ago
Christian Heimes
1526582df6
Partly revert ad3824a90261 and add comment about reference ownership
14 years ago