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

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

Issue 9124006: Blacklist types from core library, issue 969 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Use Set for checking type names. Created 8 years, 11 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 74f5475e144b85ce9fa2a13cc826608c4e420619..b431b7c60af0334e9340d0a328995e01ecee5a5c 100644
--- a/compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java
+++ b/compiler/java/com/google/dart/compiler/resolver/ResolutionContext.java
@@ -201,10 +201,10 @@ public class ResolutionContext implements ResolutionErrorListener {
isFactory,
errorCode);
case NONE:
- if (identifier.toString().equals("void")) {
+ if (Elements.isIdentifierName(identifier, "void")) {
return typeProvider.getVoidType();
}
- if (identifier.toString().equals("Dynamic")) {
+ if (Elements.isIdentifierName(identifier, "Dynamic")) {
return typeProvider.getDynamicType();
}
break;

Powered by Google App Engine
This is Rietveld 408576698