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

Unified Diff: pkg/analyzer/lib/src/generated/element.dart

Issue 1165213002: Create a TypeDefiningElement interface. (Closed) Base URL: git@github.com:dart-lang/sdk.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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 9e7eeff77d39a069fc51ad89b4e669c122ab2da0..ce028ff5658a21c43cbb4f8edf6bc5e341943821 100644
--- a/pkg/analyzer/lib/src/generated/element.dart
+++ b/pkg/analyzer/lib/src/generated/element.dart
@@ -128,7 +128,7 @@ class CircularTypeImpl extends DynamicTypeImpl {
/**
* An element that represents a class.
*/
-abstract class ClassElement implements Element {
+abstract class ClassElement implements TypeDefiningElement {
/**
* An empty list of class elements.
*/
@@ -268,6 +268,7 @@ abstract class ClassElement implements Element {
/**
* Return the type defined by the class.
*/
+ @override
Brian Wilkerson 2015/06/08 18:22:24 We generally remove the comments for overriding me
Paul Berry 2015/06/08 18:26:24 Done.
InterfaceType get type;
/**
@@ -2154,7 +2155,7 @@ class DefaultParameterElementImpl extends ParameterElementImpl
/**
* The synthetic element representing the declaration of the type `dynamic`.
*/
-class DynamicElementImpl extends ElementImpl {
+class DynamicElementImpl extends ElementImpl implements TypeDefiningElement {
/**
* Return the unique instance of this class.
*/
@@ -2164,6 +2165,7 @@ class DynamicElementImpl extends ElementImpl {
/**
* The type defined by this element.
*/
+ @override
DynamicTypeImpl type;
/**
@@ -4371,7 +4373,7 @@ abstract class FunctionType implements ParameterizedType {
/**
* A function type alias (`typedef`).
*/
-abstract class FunctionTypeAliasElement implements Element {
+abstract class FunctionTypeAliasElement implements TypeDefiningElement {
/**
* An empty array of type alias elements.
*/
@@ -4397,6 +4399,7 @@ abstract class FunctionTypeAliasElement implements Element {
/**
* Return the type of function defined by this type alias.
*/
+ @override
FunctionType get type;
/**
@@ -9624,6 +9627,16 @@ class TopLevelVariableElementImpl extends PropertyInducingElementImpl
}
/**
+ * An element that defines a type.
+ */
+abstract class TypeDefiningElement implements Element {
+ /**
+ * Return the type defined by this element.
+ */
+ DartType get type;
+}
+
+/**
* The abstract class `TypeImpl` implements the behavior common to objects
* representing the declared type of elements in the element model.
*/
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698