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

Side by Side Diff: dart/runtime/lib/invocation_mirror_patch.dart

Issue 14251021: Move invokeOn to InstanceMirror. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | dart/runtime/lib/mirrors_impl.dart » ('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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 class _InvocationMirror implements Invocation { 5 class _InvocationMirror implements Invocation {
6 // Constants describing the invocation type. 6 // Constants describing the invocation type.
7 // _FIELD cannot be generated by regular invocation mirrors. 7 // _FIELD cannot be generated by regular invocation mirrors.
8 static const int _METHOD = 0; 8 static const int _METHOD = 0;
9 static const int _GETTER = 1; 9 static const int _GETTER = 1;
10 static const int _SETTER = 2; 10 static const int _SETTER = 2;
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 List arguments) { 119 List arguments) {
120 return new _InvocationMirror(functionName, argumentsDescriptor, arguments); 120 return new _InvocationMirror(functionName, argumentsDescriptor, arguments);
121 } 121 }
122 122
123 static _invoke(Object receiver, 123 static _invoke(Object receiver,
124 String functionName, 124 String functionName,
125 List argumentsDescriptor, 125 List argumentsDescriptor,
126 List arguments) 126 List arguments)
127 native "InvocationMirror_invoke"; 127 native "InvocationMirror_invoke";
128 128
129 invokeOn(Object receiver) { 129 _invokeOn(Object receiver) {
130 return _invoke(receiver, _functionName, _argumentsDescriptor, _arguments); 130 return _invoke(receiver, _functionName, _argumentsDescriptor, _arguments);
131 } 131 }
132
133 // TODO(ahe): This is a hack. See _LocalInstanceMirrorImpl.delegate
134 // in mirrors_impl.dart
135 static final _invokeOnClosure = (x, y) => y._invokeOn(x);
132 } 136 }
133
OLDNEW
« no previous file with comments | « no previous file | dart/runtime/lib/mirrors_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698