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

Side by Side Diff: dart/sdk/lib/_internal/compiler/implementation/js_emitter/code_emitter_task.dart

Issue 59073003: Version 0.8.10.4 (Closed) Base URL: http://dart.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 1 month 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 part of dart2js.js_emitter; 5 part of dart2js.js_emitter;
6 6
7 /** 7 /**
8 * Generates the code for all used classes in the program. Static fields (even 8 * Generates the code for all used classes in the program. Static fields (even
9 * in classes) are ignored, since they can be treated as non-class elements. 9 * in classes) are ignored, since they can be treated as non-class elements.
10 * 10 *
(...skipping 941 matching lines...) Expand 10 before | Expand all | Expand 10 after
952 js('init.dispatchPropertyName = property')))])])()); 952 js('init.dispatchPropertyName = property')))])])());
953 } 953 }
954 954
955 String generateDispatchPropertyName(int seed) { 955 String generateDispatchPropertyName(int seed) {
956 // TODO(sra): MD5 of contributing source code or URIs? 956 // TODO(sra): MD5 of contributing source code or URIs?
957 return '___dart_dispatch_record_ZxYxX_${seed}_'; 957 return '___dart_dispatch_record_ZxYxX_${seed}_';
958 } 958 }
959 959
960 emitMain(CodeBuffer buffer) { 960 emitMain(CodeBuffer buffer) {
961 if (compiler.isMockCompilation) return; 961 if (compiler.isMockCompilation) return;
962 Element main = compiler.mainApp.find(Compiler.MAIN); 962 Element main = compiler.mainFunction;
963 String mainCall = null; 963 String mainCall = null;
964 if (compiler.hasIsolateSupport()) { 964 if (compiler.hasIsolateSupport()) {
965 Element isolateMain = 965 Element isolateMain =
966 compiler.isolateHelperLibrary.find(Compiler.START_ROOT_ISOLATE); 966 compiler.isolateHelperLibrary.find(Compiler.START_ROOT_ISOLATE);
967 mainCall = buildIsolateSetup(buffer, main, isolateMain); 967 mainCall = buildIsolateSetup(buffer, main, isolateMain);
968 } else { 968 } else {
969 mainCall = '${namer.isolateAccess(main)}()'; 969 mainCall = '${namer.isolateAccess(main)}()';
970 } 970 }
971 if (backend.needToInitializeDispatchProperty) { 971 if (backend.needToInitializeDispatchProperty) {
972 buffer.write( 972 buffer.write(
(...skipping 619 matching lines...) Expand 10 before | Expand all | Expand 10 after
1592 } 1592 }
1593 1593
1594 bool isDeferred(Element element) { 1594 bool isDeferred(Element element) {
1595 return compiler.deferredLoadTask.isDeferred(element); 1595 return compiler.deferredLoadTask.isDeferred(element);
1596 } 1596 }
1597 1597
1598 bool get areAnyElementsDeferred { 1598 bool get areAnyElementsDeferred {
1599 return compiler.deferredLoadTask.areAnyElementsDeferred; 1599 return compiler.deferredLoadTask.areAnyElementsDeferred;
1600 } 1600 }
1601 } 1601 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698