Skip to content

Commit 86ebf3d

Browse files
authored
Merge pull request #20034 from github/igfoo/fix_regex_in_dbscheme_parser
Kotlin: Update regex patterns to use raw string notation
2 parents 27f2000 + a6701ce commit 86ebf3d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

java/kotlin-extractor/generate_dbscheme.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,10 +35,10 @@ def parse_dbscheme(filename):
3535
unions[name] = typs
3636

3737
# tables
38-
for relname, body in re.findall('\n([\w_]+)(\([^)]*\))',
38+
for relname, body in re.findall(r'\n([\w_]+)(\([^)]*\))',
3939
dbscheme,
4040
flags=re.DOTALL):
41-
columns = list(re.findall('(\S+)\s*:\s*([^\s,]+)(?:\s+(ref)|)', body))
41+
columns = list(re.findall(r'(\S+)\s*:\s*([^\s,]+)(?:\s+(ref)|)', body))
4242
tables[relname] = columns
4343

4444
parse_dbscheme(dbscheme)

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy