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

Side by Side Diff: pkg/analyzer/lib/src/error/codes.dart

Issue 2983293002: Remove toplevel inference restriction hints, and restore as much (Closed)
Patch Set: Keep error filter Created 3 years, 5 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 unified diff | Download patch
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/link.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library analyzer.src.error.codes; 5 library analyzer.src.error.codes;
6 6
7 import 'package:analyzer/error/error.dart'; 7 import 'package:analyzer/error/error.dart';
8 8
9 export 'package:analyzer/src/analysis_options/error/option_codes.dart'; 9 export 'package:analyzer/src/analysis_options/error/option_codes.dart';
10 export 'package:analyzer/src/dart/error/hint_codes.dart'; 10 export 'package:analyzer/src/dart/error/hint_codes.dart';
(...skipping 4984 matching lines...) Expand 10 before | Expand all | Expand 10 after
4995 ErrorType.COMPILE_TIME_ERROR, 4995 ErrorType.COMPILE_TIME_ERROR,
4996 'NOT_INSTANTIATED_BOUND', 4996 'NOT_INSTANTIATED_BOUND',
4997 "Type parameter bound types must be instantiated.", 4997 "Type parameter bound types must be instantiated.",
4998 "Try adding type arguments."); 4998 "Try adding type arguments.");
4999 4999
5000 /* 5000 /*
5001 * TODO(brianwilkerson) Make the TOP_LEVEL_ error codes be errors rather than 5001 * TODO(brianwilkerson) Make the TOP_LEVEL_ error codes be errors rather than
5002 * hints and then clean up the function _errorSeverity in 5002 * hints and then clean up the function _errorSeverity in
5003 * test/src/task/strong/strong_test_helper.dart. 5003 * test/src/task/strong/strong_test_helper.dart.
5004 */ 5004 */
5005 /* TODO(leafp) Delete most of these.
5006 */
5005 static const StrongModeCode TOP_LEVEL_CYCLE = const StrongModeCode( 5007 static const StrongModeCode TOP_LEVEL_CYCLE = const StrongModeCode(
5006 ErrorType.HINT, 5008 ErrorType.HINT,
5007 'TOP_LEVEL_CYCLE', 5009 'TOP_LEVEL_CYCLE',
5008 "The type of '{0}' can't be inferred because it depends on itself through the cycle: {1}.", 5010 "The type of '{0}' can't be inferred because it depends on itself through the cycle: {1}.",
5009 "Try adding an explicit type to one or more of the variables in the cycle in order to break the cycle."); 5011 "Try adding an explicit type to one or more of the variables in the cycle in order to break the cycle.");
5010 5012
5011 static const StrongModeCode TOP_LEVEL_FUNCTION_LITERAL_BLOCK = 5013 static const StrongModeCode TOP_LEVEL_FUNCTION_LITERAL_BLOCK =
5012 const StrongModeCode( 5014 const StrongModeCode(
5013 ErrorType.HINT, 5015 ErrorType.HINT,
5014 'TOP_LEVEL_FUNCTION_LITERAL_BLOCK', 5016 'TOP_LEVEL_FUNCTION_LITERAL_BLOCK',
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
5063 * created from the optional [correction] template. 5065 * created from the optional [correction] template.
5064 */ 5066 */
5065 const StrongModeCode(ErrorType type, String name, String message, 5067 const StrongModeCode(ErrorType type, String name, String message,
5066 [String correction]) 5068 [String correction])
5067 : type = type, 5069 : type = type,
5068 super('STRONG_MODE_$name', message, correction); 5070 super('STRONG_MODE_$name', message, correction);
5069 5071
5070 @override 5072 @override
5071 ErrorSeverity get errorSeverity => type.severity; 5073 ErrorSeverity get errorSeverity => type.severity;
5072 } 5074 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analyzer/lib/src/summary/link.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698