From cff388c8659fb2c82d012ec72659857200a60715 Mon Sep 17 00:00:00 2001 From: Victor Lei Date: Mon, 29 Aug 2016 04:12:31 +0300 Subject: [PATCH] fixed --- smop/backend.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/smop/backend.py b/smop/backend.py index aa117281..7a057c58 100644 --- a/smop/backend.py +++ b/smop/backend.py @@ -367,12 +367,12 @@ def _backend(self,level=0): @extend(node.string) def _backend(self,level=0): if "\n" in self.value: - fmt = '"""%s"""' - elif options.strings == "C": - fmt = '"%s"' % self.value.replace('"',r'\"') - elif options.strings == "F": - fmt = "'%s'" % self.value.replace("'",r"''") - return fmt % self.value + return '"""%s"""' % self.value + if options.strings == "C": + return 'r"%s"' % self.value.replace('"',r'\"') + if options.strings == "F": + return "r'%s'" % self.value.replace("'",r"''") + assert 0 @extend(node.sub) def _backend(self,level=0):