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

Unified Diff: pkg/compiler/lib/src/platform_configuration.dart

Issue 2897903003: Support loading binary data in dart2js (Closed)
Patch Set: Updated cf. comments Created 3 years, 7 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 | « pkg/compiler/lib/src/old_to_new_api.dart ('k') | pkg/compiler/lib/src/serialization/equivalence.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/platform_configuration.dart
diff --git a/pkg/compiler/lib/src/platform_configuration.dart b/pkg/compiler/lib/src/platform_configuration.dart
index e721001786b15751cd1f229b590582f021c0a1c1..471f7ca4e9820c67b59d1722096df19b6d95b644 100644
--- a/pkg/compiler/lib/src/platform_configuration.dart
+++ b/pkg/compiler/lib/src/platform_configuration.dart
@@ -3,7 +3,7 @@
// BSD-style license that can be found in the LICENSE.md file.
/// Tools for loading and parsing platform-configuration files.
-library plaform_configuration;
+library platform_configuration;
import "dart:async";
@@ -133,12 +133,11 @@ final Set<String> allowedSections =
new Set.from([librariesSection, dartSpecSection, featuresSection]);
Future<Map<String, Uri>> load(Uri location, api.CompilerInput provider) {
- return provider.readFromUri(location).then((contents) {
- if (contents is String) {
- contents = contents.codeUnits;
- }
+ return provider
+ .readFromUri(location, inputKind: api.InputKind.binary)
+ .then((api.Input<List<int>> input) {
return libraryMappings(
- parseIni(contents,
+ parseIni(input.data,
allowedSections: allowedSections, sourceUri: location),
location);
});
« no previous file with comments | « pkg/compiler/lib/src/old_to_new_api.dart ('k') | pkg/compiler/lib/src/serialization/equivalence.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698