| OLD | NEW |
| 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; | 5 part of dart2js; |
| 6 | 6 |
| 7 class EnqueueTask extends CompilerTask { | 7 class EnqueueTask extends CompilerTask { |
| 8 final ResolutionEnqueuer resolution; | 8 final ResolutionEnqueuer resolution; |
| 9 final CodegenEnqueuer codegen; | 9 final CodegenEnqueuer codegen; |
| 10 | 10 |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 191 // supertypes. | 191 // supertypes. |
| 192 cls.ensureResolved(compiler); | 192 cls.ensureResolved(compiler); |
| 193 | 193 |
| 194 void processClass(ClassElement cls) { | 194 void processClass(ClassElement cls) { |
| 195 if (seenClasses.contains(cls)) return; | 195 if (seenClasses.contains(cls)) return; |
| 196 | 196 |
| 197 seenClasses.add(cls); | 197 seenClasses.add(cls); |
| 198 cls.ensureResolved(compiler); | 198 cls.ensureResolved(compiler); |
| 199 cls.implementation.forEachMember(processInstantiatedClassMember); | 199 cls.implementation.forEachMember(processInstantiatedClassMember); |
| 200 if (isResolutionQueue) { | 200 if (isResolutionQueue) { |
| 201 compiler.resolver.checkMembers(cls); | 201 compiler.resolver.checkClass(cls); |
| 202 } | 202 } |
| 203 | 203 |
| 204 if (compiler.enableTypeAssertions) { | 204 if (compiler.enableTypeAssertions) { |
| 205 // We need to register is checks and helpers for checking | 205 // We need to register is checks and helpers for checking |
| 206 // assignments to fields. | 206 // assignments to fields. |
| 207 // TODO(ngeoffray): This should really move to the backend. | 207 // TODO(ngeoffray): This should really move to the backend. |
| 208 cls.forEachLocalMember((Element member) { | 208 cls.forEachLocalMember((Element member) { |
| 209 if (!member.isInstanceMember() || !member.isField()) return; | 209 if (!member.isInstanceMember() || !member.isField()) return; |
| 210 DartType type = member.computeType(compiler); | 210 DartType type = member.computeType(compiler); |
| 211 registerIsCheck(type); | 211 registerIsCheck(type); |
| (...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 552 while(!queue.isEmpty) { | 552 while(!queue.isEmpty) { |
| 553 // TODO(johnniwinther): Find an optimal process order for codegen. | 553 // TODO(johnniwinther): Find an optimal process order for codegen. |
| 554 f(queue.removeLast()); | 554 f(queue.removeLast()); |
| 555 } | 555 } |
| 556 } | 556 } |
| 557 | 557 |
| 558 void _logSpecificSummary(log(message)) { | 558 void _logSpecificSummary(log(message)) { |
| 559 log('Compiled ${universe.generatedCode.length} methods.'); | 559 log('Compiled ${universe.generatedCode.length} methods.'); |
| 560 } | 560 } |
| 561 } | 561 } |
| OLD | NEW |