| Index: pkg/analyzer/lib/src/task/dart.dart
|
| diff --git a/pkg/analyzer/lib/src/task/dart.dart b/pkg/analyzer/lib/src/task/dart.dart
|
| index a89e52b6c7291e0ac24301059df0fec91bee446d..83a174b1a7ab35af91fd190fd8a2dc0e30e7a143 100644
|
| --- a/pkg/analyzer/lib/src/task/dart.dart
|
| +++ b/pkg/analyzer/lib/src/task/dart.dart
|
| @@ -2243,17 +2243,13 @@ class VerifyUnitTask extends SourceBasedAnalysisTask {
|
| errorReporter = new ErrorReporter(errorListener, source);
|
| TypeProvider typeProvider = context.typeProvider;
|
| //
|
| - // Prepare inputs. TODO
|
| + // Prepare inputs.
|
| //
|
| CompilationUnit unit = getRequiredInput(UNIT_INPUT);
|
| CompilationUnitElement unitElement = unit.element;
|
| LibraryElement libraryElement = unitElement.library;
|
| //
|
| - // Validate the directives
|
| - //
|
| - _validateDirectives(unit);
|
| - //
|
| - // Use the ErrorVerifier to compute the rest of the errors.
|
| + // Use the ErrorVerifier to compute errors.
|
| //
|
| ErrorVerifier errorVerifier = new ErrorVerifier(errorReporter,
|
| libraryElement, typeProvider, new InheritanceManager(libraryElement));
|
| @@ -2265,39 +2261,6 @@ class VerifyUnitTask extends SourceBasedAnalysisTask {
|
| }
|
|
|
| /**
|
| - * Check each directive in the given [unit] to see if the referenced source
|
| - * exists and report an error if it does not.
|
| - */
|
| - void _validateDirectives(CompilationUnit unit) {
|
| - for (Directive directive in unit.directives) {
|
| - if (directive is UriBasedDirective) {
|
| - _validateReferencedSource(directive);
|
| - }
|
| - }
|
| - }
|
| -
|
| - /**
|
| - * Check the given [directive] to see if the referenced source exists and
|
| - * report an error if it does not.
|
| - */
|
| - void _validateReferencedSource(UriBasedDirective directive) {
|
| - Source source = directive.source;
|
| - if (source != null) {
|
| - if (context.exists(source)) {
|
| - return;
|
| - }
|
| - } else {
|
| - // Don't report errors already reported by ParseDartTask.resolveDirective
|
| - if (directive.validate() != null) {
|
| - return;
|
| - }
|
| - }
|
| - StringLiteral uriLiteral = directive.uri;
|
| - errorReporter.reportErrorForNode(CompileTimeErrorCode.URI_DOES_NOT_EXIST,
|
| - uriLiteral, [directive.uriContent]);
|
| - }
|
| -
|
| - /**
|
| * Return a map from the names of the inputs of this kind of task to the task
|
| * input descriptors describing those inputs for a task with the
|
| * given [target].
|
|
|