Commit Graph

1064 Commits

Author SHA1 Message Date
Tim Peters 401396fc60 Get rid of hardcoded Python path (can't guess where the user installed
IDLE, and it likely changes across releases anyway).
2001-03-10 21:48:24 +00:00
Barry Warsaw 78d7dc4979 Added -o/--output-file option as per GNU msgfmt to specify the output
file instead of using inputfilename.mo
2001-03-02 16:53:54 +00:00
Martin v. Löwis 0f6b3832b9 Put current date into POT-Creation-Date; leave PO-Revision-Date for
for the translator to update; that is compatible with xgettext 0.10.35.
2001-03-01 22:56:17 +00:00
Ka-Ping Yee 895e8925d6 Call main routine in pydoc module (pydoc.cli). 2001-03-01 00:25:40 +00:00
Andrew M. Kuchling b68ef5081d Add script form of pydoc so that it's present in beta1. Currently
this just copies the __name__=='__main__' logic from pydoc.py.
    ?!ng can decide whether he wants to create a main() in pydoc, or rip
    it out of pydoc.py completely.
2001-02-28 20:55:10 +00:00
Jack Jansen 8a69373664 Dialog and Window objects are (finally) different beasts. 2001-02-27 11:05:00 +00:00
Jack Jansen d67566b0f0 Use the filename, not the pathname, in the definitions file
comment. This way the generated files are identical when generated on
different machines.
2001-02-27 11:04:20 +00:00
Barry Warsaw 75ee8f54fa main(): Slightly more informative error message when TokenError
occurs.  Also, continue processing.
2001-02-26 04:46:53 +00:00
Tim Peters af449638b6 Patch 103928: Correct zlib freeze settings for Win32. 2001-02-23 03:45:13 +00:00
Fred Drake f5d2fdf164 Hack to make this still work with Python 1.5.2. ;-( 2001-02-16 22:13:48 +00:00
Tim Peters 9ae2148ada Moved SequenceMatcher from ndiff into new std library module difflib.py.
Guido told me to do this <wink>.
Greatly expanded docstrings, and fleshed out with examples.
New std test.
Added new get_close_matches() function for ESR.
Needs docs, but LaTeXification of the module docstring is all it needs.
\CVS: ----------------------------------------------------------------------
2001-02-10 08:00:53 +00:00
Tim Peters 670fa52698 Whitespace normalization. 2001-02-09 21:23:21 +00:00
Jeremy Hylton 1eab0028e6 move "from Tkinter import *" to module level 2001-02-02 20:07:46 +00:00
Barry Warsaw 1bbc048310 Special case around some of the nastier annoyances with the type-in
fields.  You can now backspace out the 0 in 0x0, and you can clear the
field when in decimal mode.  There are still some oddities about
typing into these fields, but it should be much less annoying.  The
real solution is to ditch the update-while-typing "feature".
2001-02-01 21:31:58 +00:00
Barry Warsaw 74a7ece9f3 Move the "from Tkinter import *" out of the method and into the module
scope (still inside the __name__=='__main__' guard).  Necessitated by
recent addition of nested scopes.
2001-02-01 20:52:08 +00:00
Martin v. Löwis 646ddec41f Allow installation of IDLE via distutils (patch #103138). 2001-01-28 11:01:50 +00:00
Tim Peters 19f52c2e34 Windows: ucnhash subproject no longer exists (/F merged into unicodedata). 2001-01-24 10:07:22 +00:00
Fredrik Lundh b2dfd73bdc Unicode nits: Don't include unicodedatabase.h no more. And make sure
to build *all* tables in makeunicodedata.py.
2001-01-21 23:31:52 +00:00
Fredrik Lundh 7b7dd107b3 compress unicode decomposition tables (this saves another 55k) 2001-01-21 22:41:08 +00:00
Fredrik Lundh 9e9bcda547 forgot to check in the new makeunicodedata.py script 2001-01-21 17:01:31 +00:00
Tim Peters d5d2cd149f Color all word instances of "as" after "import", & on the same line, as if
keywords.  Cheap approximation to the truth.
2001-01-19 10:41:49 +00:00
Guido van Rossum 9d593a526b This still mentioned IdlePrefs.py as the place to edit color
preferences.  It is now in config.txt or ~/.idle.
2001-01-19 03:30:58 +00:00
Tim Peters 79b334ba55 Hand repair of cases where reindent changed lines of the form
\t\t\t\t\treal code
##\t\t\t\t\tunused code
\t\t\t\t\treal code

via untabifying and shifting the real code left.  Semantically the
same but made the intent of the commented-out-in-column-0 unused code
unclear.  The exact same unused code appears to have gotten copied from
file to file over the years.
2001-01-17 09:13:33 +00:00
Tim Peters 70c4378dbc Whitespace normalization. 2001-01-17 08:48:39 +00:00
Guido van Rossum ecc463a617 New, improved README from Mike Clarkson. Wow! 2001-01-03 23:50:59 +00:00
Marc-André Lemburg a866df806d This patch changes the default behaviour of the builtin charmap
codec to not apply Latin-1 mappings for keys which are not found
in the mapping dictionaries, but instead treat them as undefined
mappings.

The patch was originally written by Martin v. Loewis with some
additional (cosmetic) changes and an updated test script
by Marc-Andre Lemburg.

The standard codecs were recreated from the most current files
available at the Unicode.org site using the Tools/scripts/gencodec.py
tool.

This patch closes the bugs #116285 and #119960.
2001-01-03 21:29:14 +00:00
Guido van Rossum ef92edd903 Make the test program work outside IDLE. 2001-01-02 21:22:03 +00:00
Guido van Rossum b19f1e3701 Add Alt-slash to Unix keydefs (I somehow need it on RH 6.2).
Get rid of assignment to unused self.text.wordlist.
2001-01-02 18:28:52 +00:00
Guido van Rossum 88b5ae0110 Fixed snake logo and minus image by Daniel Calvelo. 2000-12-27 22:26:08 +00:00
Jack Jansen 27489d4c8c Optionally weed out duplicate prototypes for the same function (which
happens because the scanner ignores preprocessor #ifs).
2000-12-12 22:24:35 +00:00
Jack Jansen c1a4a04792 Adapted to new standard for initmodule() routine: don't call
Py_FatalError on errors.
2000-12-12 22:22:59 +00:00
Jack Jansen 7e0c0050a8 Various new standard types. 2000-12-12 22:21:39 +00:00
Jack Jansen b8c68634b3 Added support for generating a single module from multiple .h files.
Allow /* */ comments within function prototypes.
2000-12-12 22:21:11 +00:00
Tim Peters 2f1aeb950d SF bug 124051: ndiff "?" lines can be confusing. Well, they still can, but
after implementing it I liked Gregor's two-"?" line idea a lot.
2000-12-09 05:03:22 +00:00
Jeremy Hylton 4ebf3be407 a few small optimizations that seem to give a 5-10% speedup; the
further optimization of com_node makes the most difference.
2000-11-06 16:03:52 +00:00
Jeremy Hylton eefaeb78b3 move pruneNext method to correct object (doh!) 2000-11-06 03:47:39 +00:00
Jeremy Hylton 314e3fb215 Change the graph structure to contain the code generator object for
embedded code objects (e.g. functions) rather than the generated code
object.  This change means that the compiler generates code for
everything at the end, rather then generating code for each function
as it finds it.  Implementation note: _convert_LOAD_CONST in
pyassem.py must be change to call getCode().

Other changes follow.  Several changes creates extra edges between
basic blocks to reflect control flow for loops and exceptions.  These
missing edges had gone unnoticed because they do not affect the
current compilation process.

pyassem.py:
    Add _enable_debug() and _disable_debug() methods that print
    instructions and blocks to stdout as they are generated.

    Add edges between blocks for instructions like SETUP_LOOP,
    FOR_LOOP, etc.

    Add pruneNext to get rid of bogus edges remaining after
    unconditional transfer ops (e.g. JUMP_FORWARD)

    Change repr of Block to omit block length.

pycodegen.py:
    Make sure a new block is started after FOR_LOOP, etc.

    Change assert implementation to use RAISE_VARARGS 1 when there is
    no user-specified failure output.

misc.py:
    Implement __contains__ and copy for Set.
2000-11-06 03:43:11 +00:00
Jeremy Hylton a59ac0a7df If a function contains a doc string, remove the doc string node from
the function's body.

If assert is used without an error message, make the AST node None
rather than Name('None').
2000-11-06 03:33:52 +00:00
Mark Hammond d3d7bb1c31 Application of [ Patch #102226 ] freeze/modulefinder.py should use _winreg, not win32api 2000-11-06 02:49:27 +00:00
Fredrik Lundh fad27aee11 Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524
2000-11-03 20:24:15 +00:00
Tim Peters 0d430e28c0 Hack ndiff to display lines w/ leading tabs more intuitively. This synchs
ndiff w/ a custom version I made for Guido during the pre-2.0 freeze.
2000-11-01 02:51:27 +00:00
Barry Warsaw 08a8a355be Added the -D/--docstrings option for extraction of unmarked module,
class, method, and function docstrings.
2000-10-27 04:56:28 +00:00
Fred Drake 9c6850510c Remove bogus stdout redirection and use of sys.__stdout__; use
augmented print statement instead.
2000-10-26 03:56:46 +00:00
Fred Drake 33e2c3ece3 Remove bogus stdout redirection and use of sys.__stdout__; use
augmented print statement instead.
2000-10-26 03:49:15 +00:00
Guido van Rossum e752baae71 Add IDLE wish: access items of arrays 2000-10-25 21:18:12 +00:00
Jeremy Hylton 7cff7fe21f Many changes.
Reformatting -- long lines, "[ ]" -> "[]", a few indentation nits.

Replace calls to Node function (which constructed ast nodes) with
calls to actual constructors imported from ast module.

Optimize com_node (most frequently used method) for the common case --
the appropriate method is found in _dispatch.

Fix com_augassign to use class object's rather than node names
(rendered invalid by recent changes to ast)

Remove expensive tests for sequence-ness in com_stmt and
com_append_stmt. These tests should never fail; if they do, something
is really broken and exception will be raised elsewhere.

Fix com_stmt and com_append_stmt to use isinstance rather than
testing's type slot of ast node (this slot disappeared with recent
changes to ast).
2000-10-25 18:10:32 +00:00
Jeremy Hylton 628d289d12 Generated from rev 1.1 of ast.txt 2000-10-25 18:02:59 +00:00
Jeremy Hylton 66d2c1f7e5 Small optimizations in dispatch method: 1) lookup node's __class__ once
and store in local; 2) define _preorder to be dispatch (rather than
method that called dispatch).
2000-10-25 18:02:02 +00:00
Jeremy Hylton 821eee3321 Support for generation of ast.py from simple description of node
structure (ast.txt).  Usage is python astgen.py > ast.py.
2000-10-25 17:59:17 +00:00
Jeremy Hylton ac148b5fcd run the std regression test suite using bytecode produced by the compiler 2000-10-13 22:00:13 +00:00