| Index: pkg/analyzer/lib/src/dart/element/element.dart
|
| diff --git a/pkg/analyzer/lib/src/dart/element/element.dart b/pkg/analyzer/lib/src/dart/element/element.dart
|
| index 11dc96c7d2d2713166a18d3a2333849427b8eb49..02d0fa107d6991f4f5a1e409d6e9df0cae39f4bb 100644
|
| --- a/pkg/analyzer/lib/src/dart/element/element.dart
|
| +++ b/pkg/analyzer/lib/src/dart/element/element.dart
|
| @@ -1573,7 +1573,13 @@ class ElementAnnotationImpl implements ElementAnnotation {
|
| /**
|
| * The compliation unit in which this annotation appears.
|
| */
|
| - final CompilationUnitElement compilationUnit;
|
| + final CompilationUnitElementImpl compilationUnit;
|
| +
|
| + /**
|
| + * The AST of the annotation itself, cloned from the resolved AST for the
|
| + * source code.
|
| + */
|
| + Annotation annotationAst;
|
|
|
| /**
|
| * The result of evaluating this annotation as a compile-time constant
|
| @@ -1592,6 +1598,9 @@ class ElementAnnotationImpl implements ElementAnnotation {
|
| DartObject get constantValue => evaluationResult.value;
|
|
|
| @override
|
| + AnalysisContext get context => compilationUnit.library.context;
|
| +
|
| + @override
|
| bool get isDeprecated {
|
| if (element != null) {
|
| LibraryElement library = element.library;
|
| @@ -1639,6 +1648,14 @@ class ElementAnnotationImpl implements ElementAnnotation {
|
| return false;
|
| }
|
|
|
| + /**
|
| + * Get the library containing this annotation.
|
| + */
|
| + Source get librarySource => compilationUnit.librarySource;
|
| +
|
| + @override
|
| + Source get source => compilationUnit.source;
|
| +
|
| @override
|
| String toString() => '@$element';
|
| }
|
| @@ -4111,8 +4128,8 @@ class ParameterElementImpl extends VariableElementImpl
|
| /**
|
| * Creates a synthetic parameter with [name], [type] and [kind].
|
| */
|
| - factory ParameterElementImpl.synthetic(String name, DartType type,
|
| - ParameterKind kind) {
|
| + factory ParameterElementImpl.synthetic(
|
| + String name, DartType type, ParameterKind kind) {
|
| ParameterElementImpl element = new ParameterElementImpl(name, -1);
|
| element.type = type;
|
| element.synthetic = true;
|
|
|