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

Unified Diff: pkg/front_end/lib/src/fasta/kernel/kernel_library_builder.dart

Issue 3009573002: Serialize exports scopes. (Closed)
Patch Set: Created 3 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
Index: pkg/front_end/lib/src/fasta/kernel/kernel_library_builder.dart
diff --git a/pkg/front_end/lib/src/fasta/kernel/kernel_library_builder.dart b/pkg/front_end/lib/src/fasta/kernel/kernel_library_builder.dart
index b46efb28d340fd8d7ffd9bc2c15e0a78e4d1ed10..99fc60f3ec0ecb65c98690afca5e8c081ff1133c 100644
--- a/pkg/front_end/lib/src/fasta/kernel/kernel_library_builder.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/kernel_library_builder.dart
@@ -4,6 +4,8 @@
library fasta.kernel_library_builder;
+import 'dart:convert' show JSON;
+
import 'package:front_end/src/fasta/combinator.dart' as fasta;
import 'package:front_end/src/fasta/export.dart';
import 'package:front_end/src/fasta/import.dart';
@@ -780,6 +782,14 @@ class KernelLibraryBuilder
library.name = name;
library.procedures.sort(compareProcedures);
+
+ if (additionalExports != null) {
+ library.addMember(new Field(new Name("_exports#", library),
+ initializer: new StringLiteral(JSON.encode(additionalExports)),
+ isStatic: true,
+ isConst: true));
+ }
+
return library;
}

Powered by Google App Engine
This is Rietveld 408576698