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

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

Issue 1158193008: Eliminate Modifier.TYPEDEF and deprecate ClassElement.isTypedef. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 7 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
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 c59fc32d23b2540ab5d2e26b512ff848a4d2cf07..0fd8b81acf0069a64dbe9b640438262f6f73bf96 100644
--- a/pkg/analyzer/lib/src/generated/element.dart
+++ b/pkg/analyzer/lib/src/generated/element.dart
@@ -215,8 +215,10 @@ abstract class ClassElement implements Element {
bool get isProxy;
/**
- * Return `true` if this class is defined by a typedef construct.
+ * Return `true` if this class is a mixin application. Deprecated--please
+ * use [isMixinApplication] instead.
*/
+ @deprecated
bool get isTypedef;
/**
@@ -703,7 +705,8 @@ class ClassElementImpl extends ElementImpl implements ClassElement {
}
@override
- bool get isTypedef => hasModifier(Modifier.TYPEDEF);
+ @deprecated
+ bool get isTypedef => isMixinApplication;
@override
bool get isValidMixin => hasModifier(Modifier.MIXIN);
@@ -741,13 +744,6 @@ class ClassElementImpl extends ElementImpl implements ClassElement {
setModifier(Modifier.MIXIN_ERRORS_REPORTED, value);
}
- /**
- * Set whether this class is defined by a typedef construct.
- */
- void set typedef(bool isTypedef) {
- setModifier(Modifier.TYPEDEF, isTypedef);
- }
-
@override
List<TypeParameterElement> get typeParameters => _typeParameters;
@@ -8055,12 +8051,6 @@ class Modifier extends Enum<Modifier> {
*/
static const Modifier SYNTHETIC = const Modifier('SYNTHETIC', 18);
- /**
- * Indicates that a class was defined using an alias.
- * TODO(brianwilkerson) This should be renamed to 'ALIAS'.
- */
- static const Modifier TYPEDEF = const Modifier('TYPEDEF', 19);
-
static const List<Modifier> values = const [
ABSTRACT,
ASYNCHRONOUS,
@@ -8080,8 +8070,7 @@ class Modifier extends Enum<Modifier> {
REFERENCES_SUPER,
SETTER,
STATIC,
- SYNTHETIC,
- TYPEDEF
+ SYNTHETIC
];
const Modifier(String name, int ordinal) : super(name, ordinal);
« no previous file with comments | « pkg/analysis_server/lib/src/status/element_writer.dart ('k') | pkg/analyzer/lib/src/generated/element_handle.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698