OLD | NEW |
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_nodes_sexpr; | 5 library dart2js.ir_nodes_sexpr; |
6 | 6 |
7 import '../constants/values.dart'; | 7 import '../constants/values.dart'; |
8 import '../util/util.dart'; | 8 import '../util/util.dart'; |
9 import 'cps_ir_nodes.dart'; | 9 import 'cps_ir_nodes.dart'; |
10 import '../universe/call_structure.dart' show | 10 import '../universe/call_structure.dart' show |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 } | 398 } |
399 | 399 |
400 String visitFunction(FunctionConstantValue constant, _) { | 400 String visitFunction(FunctionConstantValue constant, _) { |
401 return '(Function "${constant.unparse()}")'; | 401 return '(Function "${constant.unparse()}")'; |
402 } | 402 } |
403 | 403 |
404 String visitNull(NullConstantValue constant, _) { | 404 String visitNull(NullConstantValue constant, _) { |
405 return '(Null)'; | 405 return '(Null)'; |
406 } | 406 } |
407 | 407 |
| 408 String visitNonConstant(NonConstantValue constant, _) { |
| 409 return '(NonConstant)'; |
| 410 } |
| 411 |
408 String visitInt(IntConstantValue constant, _) { | 412 String visitInt(IntConstantValue constant, _) { |
409 return '(Int ${constant.unparse()})'; | 413 return '(Int ${constant.unparse()})'; |
410 } | 414 } |
411 | 415 |
412 String visitDouble(DoubleConstantValue constant, _) { | 416 String visitDouble(DoubleConstantValue constant, _) { |
413 return '(Double ${constant.unparse()})'; | 417 return '(Double ${constant.unparse()})'; |
414 } | 418 } |
415 | 419 |
416 String visitBool(BoolConstantValue constant, _) { | 420 String visitBool(BoolConstantValue constant, _) { |
417 return '(Bool ${constant.unparse()})'; | 421 return '(Bool ${constant.unparse()})'; |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
491 void setReturnContinuation(Continuation node) { | 495 void setReturnContinuation(Continuation node) { |
492 assert(!_names.containsKey(node) || _names[node] == 'return'); | 496 assert(!_names.containsKey(node) || _names[node] == 'return'); |
493 _names[node] = 'return'; | 497 _names[node] = 'return'; |
494 } | 498 } |
495 | 499 |
496 String getName(Node node) { | 500 String getName(Node node) { |
497 if (!_names.containsKey(node)) return 'MISSING_NAME'; | 501 if (!_names.containsKey(node)) return 'MISSING_NAME'; |
498 return _names[node]; | 502 return _names[node]; |
499 } | 503 } |
500 } | 504 } |
OLD | NEW |