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

Unified Diff: compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java

Issue 9865025: Revert "Removes dartc reliance on its own libraries, now can be targeted at any implementation's li… (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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
Index: compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java
diff --git a/compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java b/compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java
index 63ae895e43907dbe0e38ac585210b1e6af962a01..4a88a5f93aab4f0480ea50c0922f6c0186a09e2a 100644
--- a/compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java
+++ b/compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java
@@ -7,14 +7,11 @@ import com.google.common.annotations.VisibleForTesting;
import com.google.dart.compiler.DartCompilationError;
import com.google.dart.compiler.DartCompilerContext;
import com.google.dart.compiler.ErrorCode;
-import com.google.dart.compiler.ErrorSeverity;
-import com.google.dart.compiler.Source;
-import com.google.dart.compiler.SystemLibraryManager;
-import com.google.dart.compiler.ast.ASTVisitor;
import com.google.dart.compiler.ast.DartFunctionExpression;
import com.google.dart.compiler.ast.DartFunctionTypeAlias;
import com.google.dart.compiler.ast.DartIdentifier;
import com.google.dart.compiler.ast.DartNode;
+import com.google.dart.compiler.ast.ASTVisitor;
import com.google.dart.compiler.ast.DartPropertyAccess;
import com.google.dart.compiler.ast.DartTypeNode;
import com.google.dart.compiler.ast.LibraryUnit;
@@ -40,8 +37,7 @@ public class ResolutionContext implements ResolutionErrorListener {
private Scope scope;
private final DartCompilerContext context;
private final CoreTypeProvider typeProvider;
- private final boolean suppressSdkWarnings;
-
+
ResolutionContext(String name, LibraryElement library, DartCompilerContext context,
CoreTypeProvider typeProvider) {
this(new Scope(name, library), context, typeProvider);
@@ -53,8 +49,6 @@ public class ResolutionContext implements ResolutionErrorListener {
this.scope = scope;
this.context = context;
this.typeProvider = typeProvider;
- this.suppressSdkWarnings = context.getCompilerConfiguration().getCompilerOptions()
- .suppressSdkWarnings();
}
ResolutionContext(LibraryUnit unit, DartCompilerContext context, CoreTypeProvider typeProvider) {
@@ -356,12 +350,6 @@ public class ResolutionContext implements ResolutionErrorListener {
}
public void onError(SourceInfo sourceInfo, ErrorCode errorCode, Object... arguments) {
- if (suppressSdkWarnings && errorCode.getErrorSeverity() == ErrorSeverity.WARNING) {
- Source source = sourceInfo.getSource();
- if (source != null && SystemLibraryManager.isDartUri(source.getUri())) {
- return;
- }
- }
context.onError(new DartCompilationError(sourceInfo, errorCode, arguments));
}

Powered by Google App Engine
This is Rietveld 408576698