Introduce refactoring for strings with %-based positional formatting (PY-3654)

This commit is contained in:
Andrey Vlasovskikh
2012-12-27 22:55:08 +04:00
parent 04eafc4693
commit 16ac7aa372
12 changed files with 94 additions and 10 deletions
@@ -0,0 +1,2 @@
a = "World"
print("%s: %s %s" % ("Error", "Hello", a))
@@ -0,0 +1 @@
print("%s: %s <selection>World</selection>" % ("Error", "Hello"))
@@ -0,0 +1,2 @@
a = "World"
print("%s: %s %s" % ("Error", "Hello", a))
@@ -0,0 +1 @@
print("%s: %s <selection>World</selection>" % ("Error", "Hello",))
@@ -0,0 +1,2 @@
a = "Hello"
print("%s %s" % (a, "World"))
@@ -0,0 +1 @@
print("<selection>Hello</selection> %s" % ("World",))
@@ -0,0 +1,2 @@
a = "Hello"
print("%s: %s %s" % ("Error", a, "World"))
@@ -0,0 +1 @@
print("%s: <selection>Hello</selection> %s" % ("Error", "World"))