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

Side by Side Diff: lib/compiler/implementation/enqueue.dart

Issue 10911181: Collect getters in a FunctionSet while resolving. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 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
« no previous file with comments | « lib/compiler/implementation/compiler.dart ('k') | lib/compiler/implementation/ssa/builder.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 class EnqueueTask extends CompilerTask { 5 class EnqueueTask extends CompilerTask {
6 final Enqueuer codegen; 6 final Enqueuer codegen;
7 final Enqueuer resolution; 7 final Enqueuer resolution;
8 8
9 String get name => 'Enqueue'; 9 String get name => 'Enqueue';
10 10
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 if (isResolutionQueue && getCachedElements(element) !== null) return; 94 if (isResolutionQueue && getCachedElements(element) !== null) return;
95 compiler.internalErrorOnElement(element, "Work list is closed."); 95 compiler.internalErrorOnElement(element, "Work list is closed.");
96 } 96 }
97 if (!isResolutionQueue && 97 if (!isResolutionQueue &&
98 element.kind === ElementKind.GENERATIVE_CONSTRUCTOR) { 98 element.kind === ElementKind.GENERATIVE_CONSTRUCTOR) {
99 registerInstantiatedClass(element.getEnclosingClass()); 99 registerInstantiatedClass(element.getEnclosingClass());
100 } 100 }
101 if (elements === null) { 101 if (elements === null) {
102 elements = getCachedElements(element); 102 elements = getCachedElements(element);
103 } 103 }
104 if (isResolutionQueue) {
105 compiler.world.registerUsedElement(element);
106 }
104 107
105 queue.add(new WorkItem(element, elements, itemCompilationContextCreator())); 108 queue.add(new WorkItem(element, elements, itemCompilationContextCreator()));
106 109
107 // Enable isolate support if we start using something from the 110 // Enable isolate support if we start using something from the
108 // isolate library. 111 // isolate library.
109 LibraryElement library = element.getLibrary(); 112 LibraryElement library = element.getLibrary();
110 if (!compiler.hasIsolateSupport() 113 if (!compiler.hasIsolateSupport()
111 && library.uri.toString() == 'dart:isolate') { 114 && library.uri.toString() == 'dart:isolate') {
112 compiler.enableIsolateSupport(library); 115 compiler.enableIsolateSupport(library);
113 } 116 }
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 void registerIsCheck(DartType type) { 346 void registerIsCheck(DartType type) {
344 universe.isChecks.add(type); 347 universe.isChecks.add(type);
345 } 348 }
346 349
347 void forEach(f(WorkItem work)) { 350 void forEach(f(WorkItem work)) {
348 while (!queue.isEmpty()) { 351 while (!queue.isEmpty()) {
349 f(queue.removeLast()); // TODO(kasperl): Why isn't this removeFirst? 352 f(queue.removeLast()); // TODO(kasperl): Why isn't this removeFirst?
350 } 353 }
351 } 354 }
352 } 355 }
OLDNEW
« no previous file with comments | « lib/compiler/implementation/compiler.dart ('k') | lib/compiler/implementation/ssa/builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698