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

Side by Side Diff: pkg/compiler/lib/src/js_emitter/new_emitter/model_emitter.dart

Issue 906713002: Extract invoke-main stub generator. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix by adding a missing semicolon. Created 5 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 dart2js.new_js_emitter.model_emitter; 5 library dart2js.new_js_emitter.model_emitter;
6 6
7 import '../../dart2jslib.dart' show Compiler; 7 import '../../dart2jslib.dart' show Compiler;
8 import '../../dart_types.dart' show DartType; 8 import '../../dart_types.dart' show DartType;
9 import '../../elements/elements.dart' show ClassElement; 9 import '../../elements/elements.dart' show ClassElement;
10 import '../../js/js.dart' as js; 10 import '../../js/js.dart' as js;
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 js.js.statement(parseFunctionDescriptorBoilerplate), 109 js.js.statement(parseFunctionDescriptorBoilerplate),
110 'cyclicThrow': 110 'cyclicThrow':
111 backend.emitter.staticFunctionAccess(backend.getCyclicThrowHelper()), 111 backend.emitter.staticFunctionAccess(backend.getCyclicThrowHelper()),
112 'outputContainsConstantList': program.outputContainsConstantList, 112 'outputContainsConstantList': program.outputContainsConstantList,
113 'embeddedGlobals': emitEmbeddedGlobals(program), 113 'embeddedGlobals': emitEmbeddedGlobals(program),
114 'constants': emitConstants(fragment.constants), 114 'constants': emitConstants(fragment.constants),
115 'staticNonFinals': 115 'staticNonFinals':
116 emitStaticNonFinalFields(fragment.staticNonFinalFields), 116 emitStaticNonFinalFields(fragment.staticNonFinalFields),
117 'operatorIsPrefix': js.string(namer.operatorIsPrefix), 117 'operatorIsPrefix': js.string(namer.operatorIsPrefix),
118 'eagerClasses': emitEagerClassInitializations(fragment.libraries), 118 'eagerClasses': emitEagerClassInitializations(fragment.libraries),
119 'main': fragment.main, 119 'invokeMain': fragment.invokeMain,
120 'code': code}; 120 'code': code};
121 121
122 holes.addAll(nativeHoles(program)); 122 holes.addAll(nativeHoles(program));
123 123
124 return js.js.statement(boilerplate, holes); 124 return js.js.statement(boilerplate, holes);
125 } 125 }
126 126
127 Map<String, dynamic> nativeHoles(Program program) { 127 Map<String, dynamic> nativeHoles(Program program) {
128 Map<String, dynamic> nativeHoles = <String, dynamic>{}; 128 Map<String, dynamic> nativeHoles = <String, dynamic>{};
129 129
(...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after
925 925
926 // Add native boilerplate code. 926 // Add native boilerplate code.
927 #nativeIsolateAffinityTagInitialization; 927 #nativeIsolateAffinityTagInitialization;
928 928
929 // Initialize eager classes. 929 // Initialize eager classes.
930 #eagerClasses; 930 #eagerClasses;
931 931
932 var end = Date.now(); 932 var end = Date.now();
933 print('Setup: ' + (end - start) + ' ms.'); 933 print('Setup: ' + (end - start) + ' ms.');
934 934
935 #main(); // Start main. 935 #invokeMain; // Start main.
936 936
937 }(Date.now(), #code) 937 }(Date.now(), #code)
938 }"""; 938 }""";
939 939
940 } 940 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_emitter/model.dart ('k') | pkg/compiler/lib/src/js_emitter/old_emitter/emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698