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

Side by Side Diff: pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart

Issue 2703253006: Turn off `strong_mode_down_cast_composite` warnings by default in Flutter projects.
Patch Set: Remove newline. Created 3 years, 10 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 | « pkg/analyzer/lib/src/context/source.dart ('k') | pkg/analyzer/lib/src/generated/source.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) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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 import 'package:analyzer/context/declared_variables.dart'; 5 import 'package:analyzer/context/declared_variables.dart';
6 import 'package:analyzer/dart/ast/ast.dart'; 6 import 'package:analyzer/dart/ast/ast.dart';
7 import 'package:analyzer/dart/ast/visitor.dart'; 7 import 'package:analyzer/dart/ast/visitor.dart';
8 import 'package:analyzer/dart/element/element.dart'; 8 import 'package:analyzer/dart/element/element.dart';
9 import 'package:analyzer/error/error.dart'; 9 import 'package:analyzer/error/error.dart';
10 import 'package:analyzer/error/listener.dart'; 10 import 'package:analyzer/error/listener.dart';
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 RecordingErrorListener errorListener = _getErrorListener(file); 242 RecordingErrorListener errorListener = _getErrorListener(file);
243 243
244 if (_analysisOptions.strongMode) { 244 if (_analysisOptions.strongMode) {
245 AnalysisOptionsImpl options = _analysisOptions as AnalysisOptionsImpl; 245 AnalysisOptionsImpl options = _analysisOptions as AnalysisOptionsImpl;
246 CodeChecker checker = new CodeChecker( 246 CodeChecker checker = new CodeChecker(
247 _typeProvider, 247 _typeProvider,
248 new StrongTypeSystemImpl(_typeProvider, 248 new StrongTypeSystemImpl(_typeProvider,
249 implicitCasts: options.implicitCasts, 249 implicitCasts: options.implicitCasts,
250 nonnullableTypes: options.nonnullableTypes), 250 nonnullableTypes: options.nonnullableTypes),
251 errorListener, 251 errorListener,
252 options); 252 options,
253 _sourceFactory.hasFlutterDependency);
253 checker.visitCompilationUnit(unit); 254 checker.visitCompilationUnit(unit);
254 } 255 }
255 256
256 ErrorReporter errorReporter = _getErrorReporter(file); 257 ErrorReporter errorReporter = _getErrorReporter(file);
257 258
258 // 259 //
259 // Validate the directives. 260 // Validate the directives.
260 // 261 //
261 _validateUriBasedDirectives(file, unit); 262 _validateUriBasedDirectives(file, unit);
262 263
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after
759 } 760 }
760 761
761 /** 762 /**
762 * Either the name or the source associated with a part-of directive. 763 * Either the name or the source associated with a part-of directive.
763 */ 764 */
764 class _NameOrSource { 765 class _NameOrSource {
765 final String name; 766 final String name;
766 final Source source; 767 final Source source;
767 _NameOrSource(this.name, this.source); 768 _NameOrSource(this.name, this.source);
768 } 769 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/context/source.dart ('k') | pkg/analyzer/lib/src/generated/source.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698