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 js_backend; | 5 part of js_backend; |
6 | 6 |
7 const VERBOSE_OPTIMIZER_HINTS = false; | 7 const VERBOSE_OPTIMIZER_HINTS = false; |
8 | 8 |
9 class JavaScriptItemCompilationContext extends ItemCompilationContext { | 9 class JavaScriptItemCompilationContext extends ItemCompilationContext { |
10 final Set<HInstruction> boundsChecked = new Set<HInstruction>(); | 10 final Set<HInstruction> boundsChecked = new Set<HInstruction>(); |
(...skipping 2559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2570 | 2570 |
2571 @override | 2571 @override |
2572 bool enableDeferredLoadingIfSupported(Spannable node, Registry registry) { | 2572 bool enableDeferredLoadingIfSupported(Spannable node, Registry registry) { |
2573 registerCheckDeferredIsLoaded(registry); | 2573 registerCheckDeferredIsLoaded(registry); |
2574 return true; | 2574 return true; |
2575 } | 2575 } |
2576 | 2576 |
2577 @override | 2577 @override |
2578 bool enableCodegenWithErrorsIfSupported(Spannable node) { | 2578 bool enableCodegenWithErrorsIfSupported(Spannable node) { |
2579 if (compiler.useCpsIr) { | 2579 if (compiler.useCpsIr) { |
| 2580 // TODO(25747): Support code generation with compile-time errors. |
2580 reporter.reportHintMessage( | 2581 reporter.reportHintMessage( |
2581 node, | 2582 node, |
2582 MessageKind.GENERIC, | 2583 MessageKind.GENERIC, |
2583 {'text': "Generation of code with compile time errors is currently " | 2584 {'text': "Generation of code with compile time errors is currently " |
2584 "not supported with the CPS IR."}); | 2585 "not supported with the CPS IR."}); |
2585 return false; | 2586 return false; |
2586 } | 2587 } |
2587 return true; | 2588 return true; |
2588 } | 2589 } |
2589 | 2590 |
(...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3182 } | 3183 } |
3183 } | 3184 } |
3184 | 3185 |
3185 @override | 3186 @override |
3186 void onImpactUsed(ImpactUseCase impactUse) { | 3187 void onImpactUsed(ImpactUseCase impactUse) { |
3187 if (impactUse == DeferredLoadTask.IMPACT_USE) { | 3188 if (impactUse == DeferredLoadTask.IMPACT_USE) { |
3188 resolution.emptyCache(); | 3189 resolution.emptyCache(); |
3189 } | 3190 } |
3190 } | 3191 } |
3191 } | 3192 } |
OLD | NEW |