Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(330)

Unified Diff: Source/bindings/scripts/compute_interfaces_info_individual.py

Issue 678453004: IDL: Use implicit false in compute_info_individual() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/bindings/scripts/compute_interfaces_info_individual.py
diff --git a/Source/bindings/scripts/compute_interfaces_info_individual.py b/Source/bindings/scripts/compute_interfaces_info_individual.py
index 3d9128d2be822e3ce164ec61007c64107224c935..87fae3ec1fcbd2ab00156558561d5e2fc5500a74 100755
--- a/Source/bindings/scripts/compute_interfaces_info_individual.py
+++ b/Source/bindings/scripts/compute_interfaces_info_individual.py
@@ -149,7 +149,7 @@ class InterfaceInfoCollector(object):
"""Reads an idl file and collects information which is required by the
binding code generation."""
definitions = self.reader.read_idl_file(idl_filename)
- if len(definitions.interfaces) > 0:
+ if definitions.interfaces:
definition = next(definitions.interfaces.itervalues())
interface_info = {
'is_callback_interface': definition.is_callback,
@@ -163,7 +163,7 @@ class InterfaceInfoCollector(object):
# [PutForwards].
'referenced_interfaces': get_put_forward_interfaces_from_definition(definition),
}
- elif len(definitions.dictionaries) > 0:
+ elif definitions.dictionaries:
definition = next(definitions.dictionaries.itervalues())
interface_info = {
'is_callback_interface': False,
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698