Commits

Author Commit Message Labels Comments Date
Guido van Rossum
Fix stupid typo.
Guido van Rossum
Convert fix_has_key to the new regime.
Guido van Rossum
Delete a straggler.
Guido van Rossum
Refactored the refactoring -- fixes now live in subpackage "fixes" and are defined by a class with a specific API. Not all fixes have been converted yet.
Guido van Rossum
Add a generic refactoring tool. As a safety measure, this doesn't modify files (yet), but prints unified diffs instead.
Guido van Rossum
Use a fixed number instead of sys.maxint. Change pattern repr. Add some pattern optimizations. Allow {N} in pattern syntax. Refactor parser driver to allow a different source of tokens than tokenize. Add a filter for tokenize that removes significant whitespace (so it can be insignificant for patterns). Close the stream from which the grammar is read if we opened it.
Guido van Rossum
Updated descriptions, added new files, added (c) notes.
Guido van Rossum
Add proper parenthesization (at least for common cases) to has_key() example.
Guido van Rossum
Added a negated pattern. Syntax appears sub-optimal, but it works. (It works like a negative look-ahead in regexes.)
Guido van Rossum
Add a pattern compiler, to take away the tedious work of building matching patterns by hand. (Still needed: a language to specify replacements, too. One thing at a time.)
Guido van Rossum
Fold two long lines. This line, and those below, will be ignored-- M 2to3/tests.py
Guido van Rossum
Minor tweaks to a docstring and a test.
Guido van Rossum
Much better wildcard pattern matching. And some unit tests.
Guido van Rossum
Add a wildcard pattern matcher. Lightly tested.
Guido van Rossum
This doesn't benefit from matching patterns (yet), but it did get broken subtly by the tree optimization change.
Guido van Rossum
Another fixer to use pattern matching.
Guido van Rossum
Add a pattern matching capability. Only one example updated to use it so far. (It needs more powerful wildcards -- it has the equivalent of '.' but not '.*'.)
Guido van Rossum
Reduce parse tree complexity by leaving out interior nodes with one child.
Neal Norwitz
Fix docstrings to reflect the refactoring
Guido van Rossum
Delete a debug print.
Guido van Rossum
Forgot to check in fix_apply.py. Added docstrings and a few more asserts to pytree.py.
Guido van Rossum
Refactoring tool for apply().
Guido van Rossum
Change replace() API to not require passing in the parent. Also, n.replace(None) deletes n from its parent.
Guido van Rossum
Completed the print stmt -> function refactoring.
Guido van Rossum
Change node constructor signatures so context is an optional keyword argument.
Guido van Rossum
Same idea, different tree node implementation.
Guido van Rossum
Update copyright notices. Everything I add is copyrighted by Google.
Guido van Rossum
Show diffs for example.py too.
Guido van Rossum
Tweak the prefix computation to handle alternative horizontal whitespace (\t, \f) properly. Change tokenize.py to return a single (NL, "\\\n") token for a backslash continuation line.
Guido van Rossum
Delete stuff we don't need.
  1. Prev
  2. Next