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

Unified Diff: editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/index/AnalysisMarkerManager.java

Issue 10855140: Issue 3562. Analyzer should not warn about shadowing (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 4 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: editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/index/AnalysisMarkerManager.java
diff --git a/editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/index/AnalysisMarkerManager.java b/editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/index/AnalysisMarkerManager.java
index 5bfaee21208122a117c048b924b5494a5011fb0c..0ea6bb59d26d577bb3a91b7c6102399492407d63 100644
--- a/editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/index/AnalysisMarkerManager.java
+++ b/editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/analysis/index/AnalysisMarkerManager.java
@@ -17,9 +17,7 @@ import com.google.dart.compiler.DartCompilationError;
import com.google.dart.compiler.ErrorCode;
import com.google.dart.compiler.ErrorSeverity;
import com.google.dart.compiler.SubSystem;
-import com.google.dart.compiler.resolver.ResolverErrorCode;
import com.google.dart.tools.core.DartCore;
-import com.google.dart.tools.core.DartCoreDebug;
import com.google.dart.tools.core.analysis.AnalysisError;
import com.google.dart.tools.core.analysis.AnalysisEvent;
import com.google.dart.tools.core.analysis.AnalysisListener;
@@ -58,10 +56,6 @@ class AnalysisMarkerManager implements AnalysisListener {
* Create an error marker for the specified file
*/
void createMarker(File file, DartCompilationError error) {
- if (DartCoreDebug.HIDE_SHADOW_WARNINGS && isShadowWarning(error)) {
- return;
- }
-
if (file == null || error == null) {
return;
}
@@ -155,18 +149,6 @@ class AnalysisMarkerManager implements AnalysisListener {
}
/**
- * @return if given {@link DartCompilationError} is warning that some element shadows other
- * element.
- */
- private static boolean isShadowWarning(DartCompilationError error) {
- ErrorCode errorCode = error.getErrorCode();
- return errorCode == ResolverErrorCode.DUPLICATE_FUNCTION_EXPRESSION_WARNING
- || errorCode == ResolverErrorCode.DUPLICATE_LOCAL_VARIABLE_WARNING
- || errorCode == ResolverErrorCode.DUPLICATE_PARAMETER_WARNING
- || errorCode == ResolverErrorCode.DUPLICATE_TYPE_VARIABLE_WARNING;
- }
-
- /**
* A collection of marker changes to be made. Synchronize against this field before accessing.
*/
private final ArrayList<MarkerOp> queue;

Powered by Google App Engine
This is Rietveld 408576698