Skip to content

Commit 7833016

Browse files
committed
Update flake8 tests
1 parent 248bc7d commit 7833016

3 files changed

Lines changed: 7 additions & 7 deletions

File tree

arch/zx48k/backend/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@
132132
OPT32 = True
133133

134134
# Label RegExp
135-
RE_LABEL = re.compile('^[ \t]*[a-zA-Z_][_a-zA-Z\d]*:')
135+
RE_LABEL = re.compile(r'^[ \t]*[a-zA-Z_][_a-zA-Z\d]*:')
136136

137137
# (ix +/- ...) regexp
138138
RE_IX_IDX = re.compile(r'^\([ \t]*ix[ \t]*[-+][ \t]*.+\)$')

arch/zx48k/optimizer.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,14 @@
4444
'bc', 'de', 'hl', 'sp', 'ix', 'iy', 'ixh', 'ixl', 'iyh', 'iyl',
4545
'af', "af'", 'i', 'r'}
4646

47-
RE_NUMBER = re.compile('^([-+]?[0-9]+|$[A-Fa-f0-9]+|[0-9][A-Fa-f0-9]*[Hh]|%[01]+|[01]+[bB])$')
47+
RE_NUMBER = re.compile(r'^([-+]?[0-9]+|$[A-Fa-f0-9]+|[0-9][A-Fa-f0-9]*[Hh]|%[01]+|[01]+[bB])$')
4848
RE_INDIR = re.compile(r'\([ \t]*[Ii][XxYy][ \t]*[-+][ \t]*[0-9]+[ \t]*\)')
4949
RE_IXIND = re.compile(r'[iI][xXyY]([-+][0-9]+)?')
5050
RE_LABEL = re.compile(r'^[ \t]*[_a-zA-Z][a-zA-Z\d]*:')
51-
RE_INDIR16 = re.compile('r[ \t]*\([ \t]*([dD][eE])|([hH][lL])[ \t]*\)[ \t]*')
52-
RE_OUTC = re.compile('[ \t]*\([ \t]*[cC]\)')
53-
RE_ID = re.compile('[.a-zA-Z_][.a-zA-Z_0-9]*')
54-
RE_PRAGMA = re.compile('^#[ \t]?pragma[ \t]opt[ \t]')
51+
RE_INDIR16 = re.compile(r'[ \t]*\([ \t]*([dD][eE])|([hH][lL])[ \t]*\)[ \t]*')
52+
RE_OUTC = re.compile(r'[ \t]*\([ \t]*[cC]\)')
53+
RE_ID = re.compile(r'[.a-zA-Z_][.a-zA-Z_0-9]*')
54+
RE_PRAGMA = re.compile(r'^#[ \t]?pragma[ \t]opt[ \t]')
5555

5656
# Enabled Optimizations (this is useful for debugging)
5757
OPT00 = True

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ commands =
1616

1717
[flake8]
1818
max-line-length = 120
19-
ignore = E722, E731, E741
19+
ignore = E722, E731, E741, W504
2020
exclude =
2121
.cache/,
2222
.tox/,

0 commit comments

Comments
 (0)