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

Side by Side Diff: tool/input_sdk/private/js_mirrors.dart

Issue 1183033004: js_ast: implement rest/spread parsing (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « lib/src/js/template.dart ('k') | tool/sdk_expected_errors.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library dart._js_mirrors; 5 library dart._js_mirrors;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 import 'dart:mirrors'; 8 import 'dart:mirrors';
9 import 'dart:_foreign_helper' show JS; 9 import 'dart:_foreign_helper' show JS;
10 import 'dart:_internal' as _internal; 10 import 'dart:_internal' as _internal;
(...skipping 23 matching lines...) Expand all
34 34
35 dynamic _dload(obj, String name) { 35 dynamic _dload(obj, String name) {
36 return JS('', '#.dload(#, #)', _dart, obj, name); 36 return JS('', '#.dload(#, #)', _dart, obj, name);
37 } 37 }
38 38
39 void _dput(obj, String name, val) { 39 void _dput(obj, String name, val) {
40 JS('', '#.dput(#, #, #)', _dart, obj, name, val); 40 JS('', '#.dput(#, #, #)', _dart, obj, name, val);
41 } 41 }
42 42
43 dynamic _dsend(obj, String name, List args) { 43 dynamic _dsend(obj, String name, List args) {
44 return JS('', '#.dsendArray(#, #, #)', _dart, obj, name, args); 44 return JS('', '#.dsend(#, #, ...#)', _dart, obj, name, args);
45 } 45 }
46 46
47 class JsInstanceMirror implements InstanceMirror { 47 class JsInstanceMirror implements InstanceMirror {
48 final Object reflectee; 48 final Object reflectee;
49 49
50 JsInstanceMirror._(this.reflectee); 50 JsInstanceMirror._(this.reflectee);
51 51
52 InstanceMirror getField(Symbol symbol) { 52 InstanceMirror getField(Symbol symbol) {
53 var name = getName(symbol); 53 var name = getName(symbol);
54 var field = _dload(reflectee, name); 54 var field = _dload(reflectee, name);
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 for (var i = 0; i < opts.length; ++i) { 167 for (var i = 0; i < opts.length; ++i) {
168 var type = opts[i]; 168 var type = opts[i];
169 // TODO(vsm): Recover the param name. 169 // TODO(vsm): Recover the param name.
170 var param = new JsParameterMirror._('', type); 170 var param = new JsParameterMirror._('', type);
171 params[i + args.length] = param; 171 params[i + args.length] = param;
172 } 172 }
173 173
174 return params; 174 return params;
175 } 175 }
176 } 176 }
OLDNEW
« no previous file with comments | « lib/src/js/template.dart ('k') | tool/sdk_expected_errors.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698