Chromium Code Reviews| Index: tests/compiler/dart2js/mock_compiler.dart |
| diff --git a/tests/compiler/dart2js/mock_compiler.dart b/tests/compiler/dart2js/mock_compiler.dart |
| index 6563d51feae7bac8b9f474c56d0976c5078f6ceb..a62e335aa9289081c69fc2b8aed55e3af72180fa 100644 |
| --- a/tests/compiler/dart2js/mock_compiler.dart |
| +++ b/tests/compiler/dart2js/mock_compiler.dart |
| @@ -196,11 +196,10 @@ void compareWarningKinds(String text, expectedWarnings, foundWarnings) { |
| void importLibrary(LibraryElement target, LibraryElement imported, |
| Compiler compiler) { |
| - for (Link<Element> link = imported.topLevelElements; !link.isEmpty(); |
| - link = link.tail) { |
| - compiler.withCurrentElement(link.head, () { |
| - target.define(link.head, compiler); |
| - }); |
| + for (var element in imported.localMembers) { |
|
ahe
2012/08/14 12:45:26
This is a test, so I don't mind using for-in.
|
| + compiler.withCurrentElement(element, () { |
| + target.addToScope(element, compiler); |
| + }); |
| } |
| } |