diff options
author | Simon Feltman <sfeltman@src.gnome.org> | 2014-04-28 22:57:00 -0700 |
---|---|---|
committer | Thomas A Caswell <tcaswell@gmail.com> | 2015-09-29 14:44:50 -0400 |
commit | e09c0a2bca45016daee064669ef5b1c9a748a566 (patch) | |
tree | 567ce836ed738a0a8161c11602cb135c2a77375e /giscanner/maintransformer.py | |
parent | d9a9f70ef6e3b1ef0f4baccf94780d286e51bbb0 (diff) | |
download | gobject-introspection-e09c0a2bca45016daee064669ef5b1c9a748a566.tar.gz |
giscanner: Use items() instead of iteritems()
Replace usage of iteritems() and itervalues() with items() and values()
respectively.
https://bugzilla.gnome.org/show_bug.cgi?id=679438
Diffstat (limited to 'giscanner/maintransformer.py')
-rw-r--r-- | giscanner/maintransformer.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/giscanner/maintransformer.py b/giscanner/maintransformer.py index 2871abac..f2949822 100644 --- a/giscanner/maintransformer.py +++ b/giscanner/maintransformer.py @@ -74,14 +74,14 @@ class MainTransformer(object): self._namespace.walk(self._pass_type_resolution) # Generate a reverse mapping "bar_baz" -> BarBaz - for node in self._namespace.itervalues(): + for node in self._namespace.values(): if isinstance(node, ast.Registered) and node.get_type is not None: self._uscore_type_names[node.c_symbol_prefix] = node elif isinstance(node, (ast.Record, ast.Union)): uscored = to_underscores_noprefix(node.name).lower() self._uscore_type_names[uscored] = node - for node in list(self._namespace.itervalues()): + for node in list(self._namespace.values()): if isinstance(node, ast.Function): # Discover which toplevel functions are actually methods self._pair_function(node) @@ -980,14 +980,14 @@ the ones that failed to resolve removed.""" # but only covers enums that are registered as GObject enums. # Create a fallback mapping based on all known enums in this module. uscore_enums = {} - for enum in self._namespace.itervalues(): + for enum in self._namespace.values(): if not isinstance(enum, ast.Enum): continue uscored = to_underscores_noprefix(enum.name).lower() uscore_enums[uscored] = enum uscore_enums[enum.name] = enum - for node in self._namespace.itervalues(): + for node in self._namespace.values(): if not isinstance(node, ast.ErrorQuarkFunction): continue full = node.symbol[:-len('_quark')] |