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

Unified Diff: tools/dom/scripts/htmldartgenerator.py

Issue 1885943002: Scripts shouldn't add a non-null check in dart2js for a nullable parameter (seeWebGl.texImage2D) (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 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 | « sdk/lib/web_gl/dart2js/web_gl_dart2js.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/dom/scripts/htmldartgenerator.py
diff --git a/tools/dom/scripts/htmldartgenerator.py b/tools/dom/scripts/htmldartgenerator.py
index 89e3c3a7a283590744f89bd60a927482d0827755..007f3f5bd0665e9e233f8de41434e7002a419f48 100644
--- a/tools/dom/scripts/htmldartgenerator.py
+++ b/tools/dom/scripts/htmldartgenerator.py
@@ -420,7 +420,7 @@ class HtmlDartGenerator(object):
else:
checks.append('(%s is %s)' % (
parameter_name, test_type))
- elif i >= number_of_required_in_dart:
+ elif i >= number_of_required_in_dart and not argument.type.nullable:
checks.append('%s != null' % parameter_name)
# There can be multiple presence checks. We need them all since a later
« no previous file with comments | « sdk/lib/web_gl/dart2js/web_gl_dart2js.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698