From 6ba9be3a3e32d5c6a7d7dc3f8956f4f2fa0c5db1 Mon Sep 17 00:00:00 2001 From: Stefan Behnel Date: Wed, 12 Jan 2011 22:13:43 +0100 Subject: [PATCH] fix #641: parsing of raw strings --- Cython/Compiler/Parsing.py | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/Cython/Compiler/Parsing.py b/Cython/Compiler/Parsing.py index 3c314623..938683d4 100644 --- a/Cython/Compiler/Parsing.py +++ b/Cython/Compiler/Parsing.py @@ -766,17 +766,10 @@ def p_string_literal(s, kind_override=None): has_non_ASCII_literal_characters = True elif sy == 'ESCAPE': if is_raw: - if systr == u'\\\n': - chars.append(u'\\\n') - elif systr == u'\\\"': - chars.append(u'"') - elif systr == u'\\\'': - chars.append(u"'") - else: - chars.append(systr) - if is_python3_source and not has_non_ASCII_literal_characters \ - and check_for_non_ascii_characters(systr): - has_non_ASCII_literal_characters = True + chars.append(systr) + if is_python3_source and not has_non_ASCII_literal_characters \ + and check_for_non_ascii_characters(systr): + has_non_ASCII_literal_characters = True else: c = systr[1] if c in u"01234567": -- 2.26.2