Skip to content

Commit f7d29c5

Browse files
author
James William Pye
committed
Use the re from the globals.
1 parent 5de6133 commit f7d29c5

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

postgresql/string.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def quote_ident(text):
4646
| (\$(?:[^0-9$]\w*)?\$).*?(?:\1|$) (?# Dollar quotes $$str$$)
4747
""")
4848

49-
def split(text, re = quote_re):
49+
def split(text):
5050
"""
5151
split the string up by into non-quoted and quoted portions. Zero and even
5252
numbered indexes are unquoted portions, while odd indexes are quoted
@@ -66,6 +66,7 @@ def split(text, re = quote_re):
6666
to identify the best course of action for the given split.
6767
"""
6868
lastend = 0
69+
re = quote_re
6970
scan = re.scanner(text)
7071
match = scan.search()
7172
while match is not None:

0 commit comments

Comments
 (0)