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

Unified Diff: dart/tests/compiler/dart2js/resolver_test.dart

Issue 21242002: Retain elements a finer granularity than library. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Address review comments Created 7 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
« no previous file with comments | « dart/tests/compiler/dart2js/mock_compiler.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/tests/compiler/dart2js/resolver_test.dart
diff --git a/dart/tests/compiler/dart2js/resolver_test.dart b/dart/tests/compiler/dart2js/resolver_test.dart
index 53988299ffd0aa8550d667b07640df5f9ef9133c..112ba501225bd2377db193b787fb39f5813a2103 100644
--- a/dart/tests/compiler/dart2js/resolver_test.dart
+++ b/dart/tests/compiler/dart2js/resolver_test.dart
@@ -252,7 +252,7 @@ testLocalsOne() {
MockCompiler compiler = testLocals([["foo", false], ["foo", false]]);
Expect.equals(1, compiler.errors.length);
Expect.equals(
- new Message(MessageKind.DUPLICATE_DEFINITION, {'name': 'foo'}),
+ new Message(MessageKind.DUPLICATE_DEFINITION, {'name': 'foo'}, false),
compiler.errors[0].message);
}
@@ -435,7 +435,7 @@ testTypeAnnotation() {
Expect.equals(
new Message(
- MessageKind.CANNOT_RESOLVE_TYPE.warning, {'typeName': 'Foo'}),
+ MessageKind.CANNOT_RESOLVE_TYPE.warning, {'typeName': 'Foo'}, false),
compiler.warnings[0].message);
VariableDefinitions definition = compiler.parsedTree;
Expect.equals(warningNode, definition.type);
@@ -462,7 +462,7 @@ testSuperclass() {
// should only the get the error once.
Expect.equals(2, compiler.errors.length);
var cannotResolveBar = new Message(MessageKind.CANNOT_RESOLVE_TYPE.error,
- {'typeName': 'Bar'});
+ {'typeName': 'Bar'}, false);
Expect.equals(cannotResolveBar, compiler.errors[0].message);
Expect.equals(cannotResolveBar, compiler.errors[1].message);
compiler.clearErrors();
@@ -487,7 +487,8 @@ testVarSuperclass() {
compiler.resolveStatement("Foo bar;");
Expect.equals(1, compiler.errors.length);
Expect.equals(
- new Message(MessageKind.CANNOT_RESOLVE_TYPE.warning, {'typeName': 'var'}),
+ new Message(
+ MessageKind.CANNOT_RESOLVE_TYPE.warning, {'typeName': 'var'}, false),
compiler.errors[0].message);
compiler.clearErrors();
}
@@ -498,7 +499,8 @@ testOneInterface() {
compiler.resolveStatement("Foo bar;");
Expect.equals(1, compiler.errors.length);
Expect.equals(
- new Message(MessageKind.CANNOT_RESOLVE_TYPE.warning, {'typeName': 'bar'}),
+ new Message(
+ MessageKind.CANNOT_RESOLVE_TYPE.warning, {'typeName': 'bar'}, false),
compiler.errors[0].message);
compiler.clearErrors();
@@ -811,7 +813,7 @@ testInitializers() {
}
map(ResolverVisitor visitor) {
- TreeElementMapping elements = visitor.mapping;
+ CollectingTreeElements elements = visitor.mapping;
return elements.map;
}
@@ -832,8 +834,8 @@ compileScript(String source) {
}
checkMemberResolved(compiler, className, memberName) {
- Element memberElement = findElement(compiler, className)
- .lookupLocalMember(memberName);
+ ClassElement cls = findElement(compiler, className);
+ Element memberElement = cls.lookupLocalMember(memberName);
Expect.isNotNull(memberElement);
Expect.isNotNull(
compiler.enqueuer.resolution.getCachedElements(memberElement));
« no previous file with comments | « dart/tests/compiler/dart2js/mock_compiler.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698