Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix python warnings in webidl binder #10022

Merged
merged 1 commit into from
Dec 12, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tools/webidl_binder.py
Original file line number Diff line number Diff line change
@@ -28,7 +28,7 @@
# Anything else defaults to legacy mode for backward compatibility.
CHECKS = os.environ.get('IDL_CHECKS') or 'DEFAULT'
# DEBUG=1 will print debug info in render_function
DEBUG = os.environ.get('IDL_VERBOSE') is '1'
DEBUG = os.environ.get('IDL_VERBOSE') == '1'

if DEBUG: print("Debug print ON, CHECKS=%s" % CHECKS)

@@ -525,7 +525,7 @@ def render_function(class_name, func_name, sigs, return_type, non_pointer, copy,

pre = ''

basic_return = 'return ' if constructor or return_type is not 'Void' else ''
basic_return = 'return ' if constructor or return_type != 'Void' else ''
return_prefix = basic_return
return_postfix = ''
if non_pointer: