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

Unified Diff: pkg/docgen/lib/src/models/model_helpers.dart

Issue 1115183002: Add ConstantConstructor to ConstantExpression system. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add test. Created 5 years, 8 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/docgen/lib/src/models/model_helpers.dart
diff --git a/pkg/docgen/lib/src/models/model_helpers.dart b/pkg/docgen/lib/src/models/model_helpers.dart
index 2a7ead3e932b8f94a08fbecf77f7172d3cf36565..7ba9208c6181bff7ab10dc33e21213b7cf5797b9 100644
--- a/pkg/docgen/lib/src/models/model_helpers.dart
+++ b/pkg/docgen/lib/src/models/model_helpers.dart
@@ -79,7 +79,7 @@ class AnnotationInfo {
}
class AnnotationCreator
- extends ConstantExpressionVisitor<AnnotationInfo, Annotation> {
+ extends ConstantExpressionVisitor<Annotation, AnnotationInfo> {
const AnnotationCreator();
@@ -144,12 +144,6 @@ class AnnotationCreator
}
@override
- Annotation visitPrimitive(PrimitiveConstantExpression exp,
- AnnotationInfo context) {
- return null;
- }
-
- @override
Annotation visitSymbol(SymbolConstantExpression exp,
AnnotationInfo context) {
return null;
@@ -172,6 +166,67 @@ class AnnotationCreator
AnnotationInfo context) {
return createAnnotation(exp.element, context);
}
+
+ @override
+ Annotation visitBool(BoolConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitBoolFromEnvironment(BoolFromEnvironmentConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitDouble(DoubleConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitInt(IntConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitIntFromEnvironment(IntFromEnvironmentConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitNamed(NamedArgumentReference exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitNull(NullConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitPositional(PositionalArgumentReference exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitString(StringConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
+
+ @override
+ Annotation visitStringFromEnvironment(
+ StringFromEnvironmentConstantExpression exp,
+ AnnotationInfo context) {
+ return null;
+ }
}
/// A declaration is private if itself is private, or the owner is private.

Powered by Google App Engine
This is Rietveld 408576698