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

Unified Diff: sdk/lib/js_util/dart2js/js_util_dart2js.dart

Issue 2755483003: Make `getProperty` and `callMethod` nullable (Closed)
Patch Set: Created 3 years, 9 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: sdk/lib/js_util/dart2js/js_util_dart2js.dart
diff --git a/sdk/lib/js_util/dart2js/js_util_dart2js.dart b/sdk/lib/js_util/dart2js/js_util_dart2js.dart
index 23a46e0a16a0a5e3bfb62ece529f5687be244ec8..ec6c09a5d69bae61551c09cb27d7bb4188b81f2b 100644
--- a/sdk/lib/js_util/dart2js/js_util_dart2js.dart
+++ b/sdk/lib/js_util/dart2js/js_util_dart2js.dart
@@ -59,11 +59,11 @@ _convertDataTree(data) {
newObject() => JS('=Object', '{}');
hasProperty(o, name) => JS('bool', '# in #', name, o);
-getProperty(o, name) => JS('Object', '#[#]', o, name);
+getProperty(o, name) => JS('Object|Null', '#[#]', o, name);
setProperty(o, name, value) => JS('', '#[#]=#', o, name, value);
callMethod(o, String method, List args) =>
- JS('Object', '#[#].apply(#, #)', o, method, o, args);
+ JS('Object|Null', '#[#].apply(#, #)', o, method, o, args);
instanceof(o, Function type) => JS('bool', '# instanceof #', o, type);
callConstructor(Function constr, List arguments) {
« 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