| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library fasta.source_loader; | 5 library fasta.source_loader; |
| 6 | 6 |
| 7 import 'dart:async' show Future; | 7 import 'dart:async' show Future; |
| 8 | 8 |
| 9 import 'dart:typed_data' show Uint8List; | 9 import 'dart:typed_data' show Uint8List; |
| 10 | 10 |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 224 } | 224 } |
| 225 for (Export export in exported.exporters) { | 225 for (Export export in exported.exporters) { |
| 226 exported.exportScope.forEach(export.addToExportScope); | 226 exported.exportScope.forEach(export.addToExportScope); |
| 227 } | 227 } |
| 228 } | 228 } |
| 229 bool wasChanged = false; | 229 bool wasChanged = false; |
| 230 do { | 230 do { |
| 231 wasChanged = false; | 231 wasChanged = false; |
| 232 for (SourceLibraryBuilder exported in both) { | 232 for (SourceLibraryBuilder exported in both) { |
| 233 for (Export export in exported.exporters) { | 233 for (Export export in exported.exporters) { |
| 234 SourceLibraryBuilder exporter = export.exporter; | |
| 235 exported.exportScope.forEach((String name, Builder member) { | 234 exported.exportScope.forEach((String name, Builder member) { |
| 236 if (exporter.addToExportScope(name, member)) { | 235 if (export.addToExportScope(name, member)) { |
| 237 wasChanged = true; | 236 wasChanged = true; |
| 238 } | 237 } |
| 239 }); | 238 }); |
| 240 } | 239 } |
| 241 } | 240 } |
| 242 } while (wasChanged); | 241 } while (wasChanged); |
| 243 builders.forEach((Uri uri, LibraryBuilder library) { | 242 builders.forEach((Uri uri, LibraryBuilder library) { |
| 244 if (library is SourceLibraryBuilder) { | 243 if (library is SourceLibraryBuilder) { |
| 245 library.addImportsToScope(); | 244 library.addImportsToScope(); |
| 246 } | 245 } |
| (...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 552 Expression throwCompileConstantError(Expression error) { | 551 Expression throwCompileConstantError(Expression error) { |
| 553 return target.backendTarget.throwCompileConstantError(coreTypes, error); | 552 return target.backendTarget.throwCompileConstantError(coreTypes, error); |
| 554 } | 553 } |
| 555 | 554 |
| 556 Expression buildCompileTimeError(Message message, int offset, Uri uri) { | 555 Expression buildCompileTimeError(Message message, int offset, Uri uri) { |
| 557 String text = target.context | 556 String text = target.context |
| 558 .format(message.withLocation(uri, offset), Severity.error); | 557 .format(message.withLocation(uri, offset), Severity.error); |
| 559 return target.backendTarget.buildCompileTimeError(coreTypes, text, offset); | 558 return target.backendTarget.buildCompileTimeError(coreTypes, text, offset); |
| 560 } | 559 } |
| 561 } | 560 } |
| OLD | NEW |