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

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

Issue 2096103002: Analyzer support for `@factory` methods (linter#253). (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Allow decls w/o a return type. Created 4 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 | pkg/analyzer/lib/src/dart/element/element.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/dart/element/element.dart
diff --git a/pkg/analyzer/lib/dart/element/element.dart b/pkg/analyzer/lib/dart/element/element.dart
index 13fbe4800383ea78306cb74c470e0bf73ba3718e..b829beed070b230382d275e103e98208b085ea62 100644
--- a/pkg/analyzer/lib/dart/element/element.dart
+++ b/pkg/analyzer/lib/dart/element/element.dart
@@ -624,6 +624,11 @@ abstract class Element implements AnalysisTarget {
bool get isDeprecated;
/**
+ * Return `true` if this element has an annotation of the form '@factory'.
+ */
+ bool get isFactory;
+
+ /**
* Return `true` if this element has an annotation of the form '@JS(..)'.
*/
bool get isJS;
@@ -819,6 +824,11 @@ abstract class ElementAnnotation implements ConstantEvaluationTarget {
bool get isDeprecated;
/**
+ * Return `true` if this annotation marks the associated member as a factory.
+ */
+ bool get isFactory;
+
+ /**
* Return `true` if this annotation marks the associated element with the `JS`
* annotation.
*/
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/dart/element/element.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698