mirror of
https://github.com/dart-lang/sdk
synced 2024-11-02 12:24:24 +00:00
Fix Object method tearoffs
R=jmesserly@google.com Review-Url: https://codereview.chromium.org/2953933002 .
This commit is contained in:
parent
89eda8a533
commit
daf960d5a4
2 changed files with 7 additions and 4 deletions
|
@ -4802,8 +4802,13 @@ class CodeGenerator extends Object
|
|||
result = _callHelper('bind(this, #, #)',
|
||||
[safeName, _emitTargetAccess(jsTarget, name, accessor)]);
|
||||
} else if (_isObjectMemberCall(target, memberName)) {
|
||||
result = _callHelper('bind(#, #, #.#)',
|
||||
[jsTarget, _propertyName(memberName), _runtimeModule, memberName]);
|
||||
var fn = js.call(
|
||||
memberName == 'noSuchMethod'
|
||||
? 'function(i) { return #.#(this, i); }'
|
||||
: 'function() { return #.#(this); }',
|
||||
[_runtimeModule, memberName]);
|
||||
result = _callHelper(
|
||||
'bind(#, #, #)', [jsTarget, _propertyName(memberName), fn]);
|
||||
} else {
|
||||
result = _callHelper('bind(#, #)', [jsTarget, safeName]);
|
||||
}
|
||||
|
|
|
@ -267,10 +267,8 @@ define(['dart_sdk', 'async_helper', 'expect', 'unittest', 'is', 'require'],
|
|||
'list_set_all_test': fail,
|
||||
'list_test_01_multi': fail,
|
||||
'list_test_none_multi': fail,
|
||||
'list_to_string2_test': fail,
|
||||
'main_test': fail,
|
||||
'map_keys2_test': fail,
|
||||
'map_to_string_test': fail,
|
||||
'map_from_iterable_test': is.firefox('<=50') ? fail : pass,
|
||||
'nan_infinity_test_01_multi': fail,
|
||||
'null_nosuchmethod_test': fail,
|
||||
|
|
Loading…
Reference in a new issue