remove unused code from Lexicon.py
authorStefan Behnel <stefan_ml@behnel.de>
Wed, 23 Oct 2013 16:59:49 +0000 (18:59 +0200)
committerStefan Behnel <stefan_ml@behnel.de>
Wed, 23 Oct 2013 16:59:49 +0000 (18:59 +0200)
Cython/Compiler/Lexicon.py

index fde089b..51fd9cc 100644 (file)
@@ -37,32 +37,6 @@ def make_lexicon():
     fltconst = (decimal_fract + Opt(exponent)) | (decimal + exponent)
     imagconst = (intconst | fltconst) + Any("jJ")
 
-    sq_string = (
-        Str("'") +
-        Rep(AnyBut("\\\n'") | (Str("\\") + AnyChar)) +
-        Str("'")
-    )
-
-    dq_string = (
-        Str('"') +
-        Rep(AnyBut('\\\n"') | (Str("\\") + AnyChar)) +
-        Str('"')
-    )
-
-    non_sq = AnyBut("'") | (Str('\\') + AnyChar)
-    tsq_string = (
-        Str("'''")
-        + Rep(non_sq | (Str("'") + non_sq) | (Str("''") + non_sq))
-        + Str("'''")
-    )
-
-    non_dq = AnyBut('"') | (Str('\\') + AnyChar)
-    tdq_string = (
-        Str('"""')
-        + Rep(non_dq | (Str('"') + non_dq) | (Str('""') + non_dq))
-        + Str('"""')
-    )
-
     beginstring = Opt(Any(string_prefixes) + Opt(Any(raw_prefixes)) |
                       Any(raw_prefixes) + Opt(Any(bytes_prefixes)) |
                       Any(char_prefixes)
@@ -76,7 +50,6 @@ def make_lexicon():
                              Str('u') + four_hex | Str('x') + two_hex |
                              Str('U') + four_hex + four_hex | AnyChar)
 
-
     deco = Str("@")
     bra = Any("([{")
     ket = Any(")]}")
@@ -102,7 +75,6 @@ def make_lexicon():
         (ket, Method('close_bracket_action')),
         (lineterm, Method('newline_action')),
 
-        #(stringlit, 'STRING'),
         (beginstring, Method('begin_string_action')),
 
         (comment, IGNORE),