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

Side by Side Diff: sdk/lib/mirrors/mirrors.dart

Issue 922023002: Implement DeclarationMirror.location for all but ParameterMirrors. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 // For the purposes of the mirrors library, we adopt a naming 5 // For the purposes of the mirrors library, we adopt a naming
6 // convention with respect to getters and setters. Specifically, for 6 // convention with respect to getters and setters. Specifically, for
7 // some variable or field... 7 // some variable or field...
8 // 8 //
9 // var myField; 9 // var myField;
10 // 10 //
(...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after
279 279
280 /** 280 /**
281 * Is this declaration top-level? 281 * Is this declaration top-level?
282 * 282 *
283 * This is defined to be equivalent to: 283 * This is defined to be equivalent to:
284 * [:mirror.owner != null && mirror.owner is LibraryMirror:] 284 * [:mirror.owner != null && mirror.owner is LibraryMirror:]
285 */ 285 */
286 bool get isTopLevel; 286 bool get isTopLevel;
287 287
288 /** 288 /**
289 * The source location of this Dart language entity. 289 * The source location of this Dart language entity, or [:null:] if the
290 * entity is synthetic.
290 * 291 *
291 * This operation is optional and may return [:null:]. 292 * This operation is optional and may throw an [UnsupportedError].
292 */ 293 */
gbracha 2015/02/13 03:00:57 So we probably should tighten the specification fo
rmacnak 2015/02/13 20:46:34 A library might not have a 'library foo' declarati
293 SourceLocation get location; 294 SourceLocation get location;
294 295
295 /** 296 /**
296 * A list of the metadata associated with this declaration. 297 * A list of the metadata associated with this declaration.
297 * 298 *
298 * Let *D* be the declaration this mirror reflects. 299 * Let *D* be the declaration this mirror reflects.
299 * If *D* is decorated with annotations *A1, ..., An* 300 * If *D* is decorated with annotations *A1, ..., An*
300 * where *n > 0*, then for each annotation *Ai* associated 301 * where *n > 0*, then for each annotation *Ai* associated
301 * with *D, 1 <= i <= n*, let *ci* be the constant object 302 * with *D, 1 <= i <= n*, let *ci* be the constant object
302 * specified by *Ai*. Then this method returns a list whose 303 * specified by *Ai*. Then this method returns a list whose
(...skipping 923 matching lines...) Expand 10 before | Expand all | Expand 10 after
1226 * 1227 *
1227 * When used as metadata on an import of "dart:mirrors", this metadata does 1228 * When used as metadata on an import of "dart:mirrors", this metadata does
1228 * not apply to the library in which the annotation is used, but instead 1229 * not apply to the library in which the annotation is used, but instead
1229 * applies to the other libraries (all libraries if "*" is used). 1230 * applies to the other libraries (all libraries if "*" is used).
1230 */ 1231 */
1231 final override; 1232 final override;
1232 1233
1233 const MirrorsUsed( 1234 const MirrorsUsed(
1234 {this.symbols, this.targets, this.metaTargets, this.override}); 1235 {this.symbols, this.targets, this.metaTargets, this.override});
1235 } 1236 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698