Index: pkg/analyzer/lib/src/generated/element.dart |
diff --git a/pkg/analyzer/lib/src/generated/element.dart b/pkg/analyzer/lib/src/generated/element.dart |
index f0c52a505c4adf230cce9d719d45904a875d95ab..617bf55cdc21878e2fed48469fce072b033ed6a9 100644 |
--- a/pkg/analyzer/lib/src/generated/element.dart |
+++ b/pkg/analyzer/lib/src/generated/element.dart |
@@ -3523,6 +3523,12 @@ abstract class ExecutableElement implements Element { |
List<FunctionElement> get functions; |
/** |
+ * Return `true` if this executable element did not have an explicit return |
+ * type specified for it. |
scheglov
2015/08/17 20:08:49
I cannot understand reading just this comment, whe
Brian Wilkerson
2015/08/18 00:07:04
Done
|
+ */ |
+ bool get hasImplicitReturnType; |
+ |
+ /** |
* Return `true` if this executable element is abstract. Executable elements |
* are abstract if they are not external and have no body. |
*/ |
@@ -3699,6 +3705,16 @@ abstract class ExecutableElementImpl extends ElementImpl |
} |
@override |
+ bool get hasImplicitReturnType => hasModifier(Modifier.IMPLICIT_TYPE); |
+ |
+ /** |
+ * Set whether this executable element has an implicit return type. |
+ */ |
+ void set hasImplicitReturnType(bool hasImplicitReturnType) { |
+ setModifier(Modifier.IMPLICIT_TYPE, hasImplicitReturnType); |
+ } |
+ |
+ @override |
bool get isAbstract => hasModifier(Modifier.ABSTRACT); |
@override |
@@ -3885,6 +3901,9 @@ abstract class ExecutableMember extends Member implements ExecutableElement { |
} |
@override |
+ bool get hasImplicitReturnType => baseElement.hasImplicitReturnType; |
+ |
+ @override |
bool get isAbstract => baseElement.isAbstract; |
@override |
@@ -8254,45 +8273,52 @@ class Modifier extends Enum<Modifier> { |
static const Modifier HAS_EXT_URI = const Modifier('HAS_EXT_URI', 10); |
/** |
+ * Indicates that the associated element did not have an explicit type |
+ * associated with it. If the element is an [ExecutableElement], then the |
+ * type being referred to is the return type. |
+ */ |
+ static const Modifier IMPLICIT_TYPE = const Modifier('IMPLICIT_TYPE', 11); |
+ |
+ /** |
* Indicates that a class can validly be used as a mixin. |
*/ |
- static const Modifier MIXIN = const Modifier('MIXIN', 11); |
+ static const Modifier MIXIN = const Modifier('MIXIN', 12); |
/** |
* Indicates that a class is a mixin application. |
*/ |
static const Modifier MIXIN_APPLICATION = |
- const Modifier('MIXIN_APPLICATION', 12); |
+ const Modifier('MIXIN_APPLICATION', 13); |
/** |
* Indicates that the value of a parameter or local variable might be mutated |
* within the context. |
*/ |
static const Modifier POTENTIALLY_MUTATED_IN_CONTEXT = |
- const Modifier('POTENTIALLY_MUTATED_IN_CONTEXT', 13); |
+ const Modifier('POTENTIALLY_MUTATED_IN_CONTEXT', 14); |
/** |
* Indicates that the value of a parameter or local variable might be mutated |
* within the scope. |
*/ |
static const Modifier POTENTIALLY_MUTATED_IN_SCOPE = |
- const Modifier('POTENTIALLY_MUTATED_IN_SCOPE', 14); |
+ const Modifier('POTENTIALLY_MUTATED_IN_SCOPE', 15); |
/** |
* Indicates that a class contains an explicit reference to 'super'. |
*/ |
static const Modifier REFERENCES_SUPER = |
- const Modifier('REFERENCES_SUPER', 15); |
+ const Modifier('REFERENCES_SUPER', 16); |
/** |
* Indicates that the pseudo-modifier 'set' was applied to the element. |
*/ |
- static const Modifier SETTER = const Modifier('SETTER', 16); |
+ static const Modifier SETTER = const Modifier('SETTER', 17); |
/** |
* Indicates that the modifier 'static' was applied to the element. |
*/ |
- static const Modifier STATIC = const Modifier('STATIC', 17); |
+ static const Modifier STATIC = const Modifier('STATIC', 18); |
/** |
* Indicates that the element does not appear in the source code but was |
@@ -8300,7 +8326,7 @@ class Modifier extends Enum<Modifier> { |
* constructors, an implicit zero-argument constructor will be created and it |
* will be marked as being synthetic. |
*/ |
- static const Modifier SYNTHETIC = const Modifier('SYNTHETIC', 18); |
+ static const Modifier SYNTHETIC = const Modifier('SYNTHETIC', 19); |
static const List<Modifier> values = const [ |
ABSTRACT, |
@@ -8314,6 +8340,7 @@ class Modifier extends Enum<Modifier> { |
GENERATOR, |
GETTER, |
HAS_EXT_URI, |
+ IMPLICIT_TYPE, |
MIXIN, |
MIXIN_APPLICATION, |
POTENTIALLY_MUTATED_IN_CONTEXT, |
@@ -10446,6 +10473,12 @@ abstract class VariableElement implements Element, ConstantEvaluationTarget { |
static const List<VariableElement> EMPTY_LIST = const <VariableElement>[]; |
/** |
+ * Return `true` if this variable element did not have an explicit type |
+ * specified for it. |
+ */ |
+ bool get hasImplicitType; |
+ |
+ /** |
* Return a synthetic function representing this variable's initializer, or |
* `null` if this variable does not have an initializer. The function will |
* have no parameters. The return type of the function will be the |
@@ -10554,6 +10587,16 @@ abstract class VariableElementImpl extends ElementImpl |
} |
@override |
+ bool get hasImplicitType => hasModifier(Modifier.IMPLICIT_TYPE); |
+ |
+ /** |
+ * Set whether this variable element has an implicit type. |
+ */ |
+ void set hasImplicitType(bool hasImplicitType) { |
+ setModifier(Modifier.IMPLICIT_TYPE, hasImplicitType); |
+ } |
+ |
+ @override |
FunctionElement get initializer => _initializer; |
/** |
@@ -10609,6 +10652,9 @@ abstract class VariableMember extends Member implements VariableElement { |
VariableElement get baseElement => super.baseElement as VariableElement; |
@override |
+ bool get hasImplicitType => baseElement.hasImplicitType; |
+ |
+ @override |
FunctionElement get initializer { |
// |
// Elements within this element should have type parameters substituted, |