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

Side by Side Diff: pkg/analyzer/lib/src/task/dart.dart

Issue 2976963002: Add --no-declaration-casts option to analyzer. (Closed)
Patch Set: Fix comment 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 | « pkg/analyzer/lib/src/generated/type_system.dart ('k') | pkg/analyzer/lib/src/task/options.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) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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.task.dart; 5 library analyzer.src.task.dart;
6 6
7 import 'dart:collection'; 7 import 'dart:collection';
8 8
9 import 'package:analyzer/dart/ast/ast.dart'; 9 import 'package:analyzer/dart/ast/ast.dart';
10 import 'package:analyzer/dart/ast/standard_resolution_map.dart'; 10 import 'package:analyzer/dart/ast/standard_resolution_map.dart';
(...skipping 5472 matching lines...) Expand 10 before | Expand all | Expand 10 after
5483 // Prepare inputs. 5483 // Prepare inputs.
5484 // 5484 //
5485 TypeProvider typeProvider = getRequiredInput(TYPE_PROVIDER_INPUT); 5485 TypeProvider typeProvider = getRequiredInput(TYPE_PROVIDER_INPUT);
5486 CompilationUnit unit = getRequiredInput(UNIT_INPUT); 5486 CompilationUnit unit = getRequiredInput(UNIT_INPUT);
5487 AnalysisOptionsImpl options = context.analysisOptions; 5487 AnalysisOptionsImpl options = context.analysisOptions;
5488 if (options.strongMode) { 5488 if (options.strongMode) {
5489 CodeChecker checker = new CodeChecker( 5489 CodeChecker checker = new CodeChecker(
5490 typeProvider, 5490 typeProvider,
5491 new StrongTypeSystemImpl(typeProvider, 5491 new StrongTypeSystemImpl(typeProvider,
5492 implicitCasts: options.implicitCasts, 5492 implicitCasts: options.implicitCasts,
5493 declarationCasts: options.declarationCasts,
5493 nonnullableTypes: options.nonnullableTypes), 5494 nonnullableTypes: options.nonnullableTypes),
5494 errorListener, 5495 errorListener,
5495 options); 5496 options);
5496 checker.visitCompilationUnit(unit); 5497 checker.visitCompilationUnit(unit);
5497 } 5498 }
5498 // 5499 //
5499 // Record outputs. 5500 // Record outputs.
5500 // 5501 //
5501 outputs[STRONG_MODE_ERRORS] = getUniqueErrors(errorListener.errors); 5502 outputs[STRONG_MODE_ERRORS] = getUniqueErrors(errorListener.errors);
5502 outputs[CREATED_RESOLVED_UNIT] = true; 5503 outputs[CREATED_RESOLVED_UNIT] = true;
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after
5868 5869
5869 @override 5870 @override
5870 bool moveNext() { 5871 bool moveNext() {
5871 if (_newSources.isEmpty) { 5872 if (_newSources.isEmpty) {
5872 return false; 5873 return false;
5873 } 5874 }
5874 currentTarget = _newSources.removeLast(); 5875 currentTarget = _newSources.removeLast();
5875 return true; 5876 return true;
5876 } 5877 }
5877 } 5878 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/generated/type_system.dart ('k') | pkg/analyzer/lib/src/task/options.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698