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

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

Issue 8966029: Report errors and warnings for hiding elements, issue 572. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fixes for comments Created 9 years 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/ClassScope.java
diff --git a/compiler/java/com/google/dart/compiler/resolver/ClassScope.java b/compiler/java/com/google/dart/compiler/resolver/ClassScope.java
index cba91e156ffed5e154b25c5edaea2de403a51a4e..13b694ca989d067a7eae47719ed6eb4c31204a8d 100644
--- a/compiler/java/com/google/dart/compiler/resolver/ClassScope.java
+++ b/compiler/java/com/google/dart/compiler/resolver/ClassScope.java
@@ -34,8 +34,13 @@ class ClassScope extends Scope {
ClassScope scope = new ClassScope(superclass.getElement(),
new Scope("library", (LibraryElement) enclosing));
element = scope.findElement(inLibrary, name);
- if (element != null) {
- return element;
+ switch (ElementKind.of(element)) {
+ case TYPE_VARIABLE:
+ return null;
+ case NONE:
+ break;
+ default:
+ return element;
}
}
for (InterfaceType supertype : classElement.getInterfaces()) {
« no previous file with comments | « client/view/ConveyorView.dart ('k') | compiler/java/com/google/dart/compiler/resolver/CompileTimeConstantResolver.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698