Skip to content

Commit 1ef719c

Browse files
committed
Use methods without iter
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
1 parent 331c9fd commit 1ef719c

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

bpython/curtsiesfrontend/interpreter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class BPythonFormatter(Formatter):
4545

4646
def __init__(self, color_scheme, **options):
4747
self.f_strings = {}
48-
for k, v in color_scheme.iteritems():
48+
for k, v in color_scheme.items():
4949
self.f_strings[k] = '\x01%s' % (v,)
5050
Formatter.__init__(self, **options)
5151

bpython/formatter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ class BPythonFormatter(Formatter):
8585

8686
def __init__(self, color_scheme, **options):
8787
self.f_strings = {}
88-
for k, v in theme_map.iteritems():
88+
for k, v in theme_map.items():
8989
self.f_strings[k] = '\x01%s' % (color_scheme[v],)
9090
if k is Parenthesis:
9191
# FIXME: Find a way to make this the inverse of the current

bpython/repl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -948,7 +948,7 @@ def tokenize(self, s, newline=False):
948948
else:
949949
stack.append((line, len(line_tokens) - 1,
950950
line_tokens, value))
951-
elif value in parens.itervalues():
951+
elif value in parens.values():
952952
saved_stack = list(stack)
953953
try:
954954
while True:

bpython/urwid.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1150,7 +1150,7 @@ def main(args=None, locals_=None, banner=None):
11501150
palette = [
11511151
(name, COLORMAP[color.lower()], 'default',
11521152
'bold' if color.isupper() else 'default')
1153-
for name, color in config.color_scheme.iteritems()]
1153+
for name, color in config.color_scheme.items()]
11541154
palette.extend([
11551155
('bold ' + name, color + ',bold', background, monochrome)
11561156
for name, color, background, monochrome in palette])

0 commit comments

Comments
 (0)