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

Unified Diff: lib/runtime/dart_runtime.js

Issue 1083763003: refactor emitMemberName to be used more consistently (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 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
Index: lib/runtime/dart_runtime.js
diff --git a/lib/runtime/dart_runtime.js b/lib/runtime/dart_runtime.js
index db7522ed0acf2931015d487ad346ea524b5f7cd7..a3f365e84435343859b965a8f84542fc71d8a594 100644
--- a/lib/runtime/dart_runtime.js
+++ b/lib/runtime/dart_runtime.js
@@ -68,17 +68,18 @@ var dart, _js_helper;
return f.apply(obj, args);
}
+ // TODO(jmesserly): rename to dcall?
function dinvokef(f/*, ...args*/) {
Jacob 2015/04/13 23:19:35 dcall seems more consistent with dart. E.g class F
Jennifer Messerly 2015/04/14 21:21:00 +1 ... yeah planning to fix this in follow up, but
let args = Array.prototype.slice.call(arguments, 1);
return checkAndCall(f, void 0, args, 'call');
}
dart.dinvokef = dinvokef;
- function dinvoke(obj, method/*, ...args*/) {
+ function dsend(obj, method/*, ...args*/) {
let args = Array.prototype.slice.call(arguments, 2);
return checkAndCall(obj[method], obj, args, method);
}
- dart.dinvoke = dinvoke;
+ dart.dsend = dsend;
function dindex(obj, index) {
return checkAndCall(obj.get, obj, [index], '[]');
@@ -88,12 +89,7 @@ var dart, _js_helper;
function dsetindex(obj, index, value) {
return checkAndCall(obj.set, obj, [index, value], '[]=');
}
- dart.dsetindex = dindex;
-
- function dbinary(left, op, right) {
- return checkAndCall(left[op], left, [right], op);
- }
- dart.dbinary = dbinary;
+ dart.dsetindex = dsetindex;
function cast(obj, type) {
// TODO(vsm): handle non-nullable types

Powered by Google App Engine
This is Rietveld 408576698