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

Unified Diff: lib/src/info.dart

Issue 1059873002: Tweaks to warning level and reporting (Closed) Base URL: https://github.com/dart-lang/dev_compiler.git@master
Patch Set: Fix up tests Created 5 years, 9 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 | « lib/src/codegen/reify_coercions.dart ('k') | lib/src/report.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/src/info.dart
diff --git a/lib/src/info.dart b/lib/src/info.dart
index caccaaf26a4431bf91d0c9768e6919099532290b..209362f93186bcdd28bc58ff37e1490cebba767c 100644
--- a/lib/src/info.dart
+++ b/lib/src/info.dart
@@ -244,7 +244,7 @@ abstract class DownCast extends Conversion {
if (expression is FunctionExpression) {
// fromT should be an exact type - this will almost certainly fail at
// runtime.
- return new InferableClosure(rules, expression, cast);
+ return new UninferredClosure(rules, expression, cast);
}
if (expression is InstanceCreationExpression) {
// fromT should be an exact type - this will almost certainly fail at
@@ -315,10 +315,9 @@ class AssignmentCast extends DownCast {
// List<String> l = [1, 2, 3]; // Inference reveals static type error
// We're marking all as warnings for now.
//
-
-// A "down cast" on a closure literal.
-class InferableClosure extends DownCast {
- InferableClosure(TypeRules rules, FunctionExpression expression, Cast cast)
+// TODO(vsm,leafp): Remove this.
+class UninferredClosure extends DownCast {
+ UninferredClosure(TypeRules rules, FunctionExpression expression, Cast cast)
: super._internal(rules, expression, cast);
final Level level = Level.WARNING;
@@ -476,7 +475,7 @@ class DynamicInvoke extends Conversion {
DartType _getConvertedType() => rules.provider.dynamicType;
String get message => '$expression requires dynamic invoke';
- Level get level => Level.WARNING;
+ Level get level => Level.INFO;
accept(AstVisitor visitor) {
if (visitor is ConversionVisitor) {
« no previous file with comments | « lib/src/codegen/reify_coercions.dart ('k') | lib/src/report.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698