diff options
author | Neal Norwitz <nnorwitz@gmail.com> | 2006-08-29 04:40:24 (GMT) |
---|---|---|
committer | Neal Norwitz <nnorwitz@gmail.com> | 2006-08-29 04:40:24 (GMT) |
commit | 2eca440c8dff47f1de8efb166f1db9c76b54eadd (patch) | |
tree | d2d20637f3b508f10924916bb6058b38afda1a59 /Lib | |
parent | 3bd844e695c8295c23d64d816bd763543cc9728f (diff) | |
download | cpython-2eca440c8dff47f1de8efb166f1db9c76b54eadd.zip cpython-2eca440c8dff47f1de8efb166f1db9c76b54eadd.tar.gz cpython-2eca440c8dff47f1de8efb166f1db9c76b54eadd.tar.bz2 |
Get rid of some more cases of backquotes. parsermodule.c doesn't compile
but looks like that was a problem before this change.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/compiler/transformer.py | 4 | ||||
-rwxr-xr-x | Lib/pydoc.py | 5 | ||||
-rwxr-xr-x | Lib/token.py | 1 |
3 files changed, 2 insertions, 8 deletions
diff --git a/Lib/compiler/transformer.py b/Lib/compiler/transformer.py index db571db..a9b971a 100644 --- a/Lib/compiler/transformer.py +++ b/Lib/compiler/transformer.py @@ -111,7 +111,6 @@ class Transformer: self._atom_dispatch = {token.LPAR: self.atom_lpar, token.LSQB: self.atom_lsqb, token.LBRACE: self.atom_lbrace, - token.BACKQUOTE: self.atom_backquote, token.NUMBER: self.atom_number, token.STRING: self.atom_string, token.NAME: self.atom_name, @@ -740,9 +739,6 @@ class Transformer: return Dict((), lineno=nodelist[0][2]) return self.com_dictsetmaker(nodelist[1]) - def atom_backquote(self, nodelist): - return Backquote(self.com_node(nodelist[1])) - def atom_number(self, nodelist): ### need to verify this matches compile.c k = eval(nodelist[0][1]) diff --git a/Lib/pydoc.py b/Lib/pydoc.py index 29c6cc4..3459fbe 100755 --- a/Lib/pydoc.py +++ b/Lib/pydoc.py @@ -1564,7 +1564,7 @@ class Helper: 'CLASSES': ('ref/types', 'class SPECIALMETHODS PRIVATENAMES'), 'MODULES': ('lib/typesmodules', 'import'), 'PACKAGES': 'import', - 'EXPRESSIONS': ('ref/summary', 'lambda or and not in is BOOLEAN COMPARISON BITWISE SHIFTING BINARY FORMATTING POWER UNARY ATTRIBUTES SUBSCRIPTS SLICINGS CALLS TUPLES LISTS DICTIONARIES BACKQUOTES'), + 'EXPRESSIONS': ('ref/summary', 'lambda or and not in is BOOLEAN COMPARISON BITWISE SHIFTING BINARY FORMATTING POWER UNARY ATTRIBUTES SUBSCRIPTS SLICINGS CALLS TUPLES LISTS DICTIONARIES'), 'OPERATORS': 'EXPRESSIONS', 'PRECEDENCE': 'EXPRESSIONS', 'OBJECTS': ('ref/objects', 'TYPES'), @@ -1587,14 +1587,13 @@ class Helper: 'IDENTIFIERS': ('ref/identifiers', 'keywords SPECIALIDENTIFIERS'), 'SPECIALIDENTIFIERS': ('ref/id-classes', ''), 'PRIVATENAMES': ('ref/atom-identifiers', ''), - 'LITERALS': ('ref/atom-literals', 'STRINGS BACKQUOTES NUMBERS TUPLELITERALS LISTLITERALS DICTIONARYLITERALS'), + 'LITERALS': ('ref/atom-literals', 'STRINGS NUMBERS TUPLELITERALS LISTLITERALS DICTIONARYLITERALS'), 'TUPLES': 'SEQUENCES', 'TUPLELITERALS': ('ref/exprlists', 'TUPLES LITERALS'), 'LISTS': ('lib/typesseq-mutable', 'LISTLITERALS'), 'LISTLITERALS': ('ref/lists', 'LISTS LITERALS'), 'DICTIONARIES': ('lib/typesmapping', 'DICTIONARYLITERALS'), 'DICTIONARYLITERALS': ('ref/dict', 'DICTIONARIES LITERALS'), - 'BACKQUOTES': ('ref/string-conversions', 'repr str STRINGS LITERALS'), 'ATTRIBUTES': ('ref/attribute-references', 'getattr hasattr setattr ATTRIBUTEMETHODS'), 'SUBSCRIPTS': ('ref/subscriptions', 'SEQUENCEMETHODS1'), 'SLICINGS': ('ref/slicings', 'SEQUENCEMETHODS2'), diff --git a/Lib/token.py b/Lib/token.py index c4db6c5..5f8d53a 100755 --- a/Lib/token.py +++ b/Lib/token.py @@ -35,7 +35,6 @@ GREATER = 21 EQUAL = 22 DOT = 23 PERCENT = 24 -BACKQUOTE = 25 LBRACE = 26 RBRACE = 27 EQEQUAL = 28 |