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

Unified Diff: dart/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart

Issue 764533002: Incremental compiler: Use addStubs for adding methods. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Merged with r42040. Created 6 years 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: dart/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
diff --git a/dart/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart b/dart/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
index b75c82efd625b4ce4e92fd7854e73fac879c2c36..2db15c7c26286c0f4c8787b561d12b6fbb3f2915 100644
--- a/dart/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
+++ b/dart/pkg/compiler/lib/src/js_emitter/old_emitter/reflection_data_parser.dart
@@ -280,15 +280,29 @@ jsAst.Expression getReflectionDataParser(String classesCollector,
mangledNamesAccess,
mangledGlobalNamesAccess]);
+ List<jsAst.Statement> incrementalSupport = <jsAst.Statement>[];
+ if (compiler.hasIncrementalSupport) {
+ incrementalSupport.add(
+ js.statement(
+ r'self.$dart_unsafe_eval.addStubs = addStubs;'));
+ }
+
return js('''
(function (reflectionData) {
"use strict";
- #; // header
- #; // processStatics
- #; // addStubs
- #; // tearOffCode
- #; // init
-})''', [header, processStatics, addStubs, tearOffCode, init]);
+ #header;
+ #processStatics;
+ #addStubs;
+ #tearOffCode;
+ #incrementalSupport;
+ #init;
+})''', {
+ 'header': header,
+ 'processStatics': processStatics,
+ 'incrementalSupport': incrementalSupport,
+ 'addStubs': addStubs,
+ 'tearOffCode': tearOffCode,
+ 'init': init});
}
« no previous file with comments | « dart/pkg/compiler/lib/src/js_emitter/old_emitter/emitter.dart ('k') | dart/pkg/dart2js_incremental/lib/library_updater.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698