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

Side by Side Diff: pkg/compiler/lib/src/cps_ir/cps_ir_tracer.dart

Issue 1161683002: dart2js cps: 'is' checks on types with type arguments. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 6 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
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 library dart2js.ir_tracer; 5 library dart2js.ir_tracer;
6 6
7 import 'dart:async' show EventSink; 7 import 'dart:async' show EventSink;
8 8
9 import 'cps_ir_nodes.dart' as cps_ir hide Function; 9 import 'cps_ir_nodes.dart' as cps_ir hide Function;
10 import '../tracer.dart'; 10 import '../tracer.dart';
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 String value = formatReference(entry.value); 229 String value = formatReference(entry.value);
230 entries.add("$key: $value"); 230 entries.add("$key: $value");
231 } 231 }
232 printStmt(dummy, "LiteralMap (${entries.join(', ')})"); 232 printStmt(dummy, "LiteralMap (${entries.join(', ')})");
233 } 233 }
234 234
235 visitTypeOperator(cps_ir.TypeOperator node) { 235 visitTypeOperator(cps_ir.TypeOperator node) {
236 String dummy = names.name(node); 236 String dummy = names.name(node);
237 String operator = node.isTypeTest ? 'is' : 'as'; 237 String operator = node.isTypeTest ? 'is' : 'as';
238 List<String> entries = new List<String>(); 238 List<String> entries = new List<String>();
239 String receiver = formatReference(node.receiver); 239 String value = formatReference(node.value);
240 printStmt(dummy, "TypeOperator ($operator $receiver ${node.type})"); 240 String kont = formatReference(node.continuation);
241 printStmt(dummy, "TypeOperator ($operator $value ${node.type}) $kont");
241 } 242 }
242 243
243 visitInvokeContinuation(cps_ir.InvokeContinuation node) { 244 visitInvokeContinuation(cps_ir.InvokeContinuation node) {
244 String dummy = names.name(node); 245 String dummy = names.name(node);
245 String kont = formatReference(node.continuation); 246 String kont = formatReference(node.continuation);
246 String args = node.arguments.map(formatReference).join(', '); 247 String args = node.arguments.map(formatReference).join(', ');
247 printStmt(dummy, "InvokeContinuation $kont ($args)"); 248 printStmt(dummy, "InvokeContinuation $kont ($args)");
248 } 249 }
249 250
250 visitBranch(cps_ir.Branch node) { 251 visitBranch(cps_ir.Branch node) {
(...skipping 406 matching lines...) Expand 10 before | Expand all | Expand 10 after
657 } 658 }
658 659
659 visitNonTailThrow(cps_ir.NonTailThrow node) { 660 visitNonTailThrow(cps_ir.NonTailThrow node) {
660 unexpectedNode(node); 661 unexpectedNode(node);
661 } 662 }
662 663
663 visitCreateInvocationMirror(cps_ir.CreateInvocationMirror node) { 664 visitCreateInvocationMirror(cps_ir.CreateInvocationMirror node) {
664 unexpectedNode(node); 665 unexpectedNode(node);
665 } 666 }
666 } 667 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698