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

Unified Diff: pkg/compiler/lib/src/js_backend/codegen/task.dart

Issue 1288013002: dart2js cps: Handle native functions, getters, and setters. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Address comments. Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/dart_types.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/js_backend/codegen/task.dart
diff --git a/pkg/compiler/lib/src/js_backend/codegen/task.dart b/pkg/compiler/lib/src/js_backend/codegen/task.dart
index d784197b177673efbf2cfc3424983d78a736760d..5d1e342ca0302335cdc02558a9d736c8e3e809a1 100644
--- a/pkg/compiler/lib/src/js_backend/codegen/task.dart
+++ b/pkg/compiler/lib/src/js_backend/codegen/task.dart
@@ -39,7 +39,7 @@ class CpsFunctionCompiler implements FunctionCompiler {
final Glue glue;
final SourceInformationStrategy sourceInformationFactory;
- // TODO(karlklose,sigurm): remove and update dart-doc of [compile].
+ // TODO(karlklose,sigurdm): remove and update dart-doc of [compile].
final FunctionCompiler fallbackCompiler;
Tracer get tracer => compiler.tracer;
@@ -65,10 +65,9 @@ class CpsFunctionCompiler implements FunctionCompiler {
JavaScriptBackend backend = compiler.backend;
return compiler.withCurrentElement(element, () {
try {
- // TODO(karlklose): remove this fallback.
- // Fallback for a few functions that we know require try-finally and
- // switch.
- if (element.isNative) {
+ // TODO(karlklose): remove this fallback when we do not need it for
+ // testing anymore.
+ if (false) {
compiler.log('Using SSA compiler for platform element $element');
return fallbackCompiler.compile(work);
}
@@ -100,11 +99,6 @@ class CpsFunctionCompiler implements FunctionCompiler {
}
cps.FunctionDefinition compileToCpsIR(AstElement element) {
- // TODO(sigurdm): Support these constructs.
- if (element.isNative) {
- giveUp('unsupported element kind: ${element.name}:${element.kind}');
- }
-
cps.FunctionDefinition cpsNode = irBuilderTask.buildNode(element);
if (cpsNode == null) {
if (irBuilderTask.bailoutMessage == null) {
« no previous file with comments | « pkg/compiler/lib/src/dart_types.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698