Skip to content

Commit 25ccaa7

Browse files
josuskytargos
authored andcommitted
tools: fix regex strings in Python tools
PR-URL: #46671 Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Tobias Nießen <[email protected]>
1 parent 7806cae commit 25ccaa7

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

tools/getsharedopensslhasquic.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def get_has_quic(include_path):
1414
except OSError:
1515
return False
1616

17-
regex = '^#\s*define OPENSSL_INFO_QUIC'
17+
regex = r'^#\s*define OPENSSL_INFO_QUIC'
1818

1919
for line in f:
2020
if (re.match(regex, line)):

tools/js2c.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ def ReadFile(filename):
9292

9393
CONFIG_GYPI_ID = 'config_raw'
9494

95-
SLUGGER_RE =re.compile('[.\-/]')
95+
SLUGGER_RE = re.compile(r'[.\-/]')
9696

9797
is_verbose = False
9898

tools/v8_gypfiles/GN-scraper.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
import re
44
import os
55

6-
PLAIN_SOURCE_RE = re.compile('\s*"([^/$].+)"\s*')
6+
PLAIN_SOURCE_RE = re.compile(r'\s*"([^/$].+)"\s*')
77
def DoMain(args):
88
gn_filename, pattern = args
99
src_root = os.path.dirname(gn_filename)

0 commit comments

Comments
 (0)