| 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 library dart2js.constant_system; | 5 library dart2js.constant_system; |
| 6 | 6 |
| 7 import '../common_elements.dart' show CommonElements; | 7 import '../common_elements.dart' show CommonElements; |
| 8 import '../elements/operators.dart'; |
| 8 import '../elements/types.dart'; | 9 import '../elements/types.dart'; |
| 9 import '../resolution/operators.dart'; | |
| 10 import '../tree/dartstring.dart' show DartString; | 10 import '../tree/dartstring.dart' show DartString; |
| 11 import 'values.dart'; | 11 import 'values.dart'; |
| 12 | 12 |
| 13 abstract class Operation { | 13 abstract class Operation { |
| 14 String get name; | 14 String get name; |
| 15 } | 15 } |
| 16 | 16 |
| 17 abstract class UnaryOperation extends Operation { | 17 abstract class UnaryOperation extends Operation { |
| 18 /** Returns [:null:] if it was unable to fold the operation. */ | 18 /** Returns [:null:] if it was unable to fold the operation. */ |
| 19 ConstantValue fold(ConstantValue constant); | 19 ConstantValue fold(ConstantValue constant); |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 136 return greaterEqual; | 136 return greaterEqual; |
| 137 case BinaryOperatorKind.EQ: | 137 case BinaryOperatorKind.EQ: |
| 138 return equal; | 138 return equal; |
| 139 case BinaryOperatorKind.IF_NULL: | 139 case BinaryOperatorKind.IF_NULL: |
| 140 return ifNull; | 140 return ifNull; |
| 141 default: | 141 default: |
| 142 return null; | 142 return null; |
| 143 } | 143 } |
| 144 } | 144 } |
| 145 } | 145 } |
| OLD | NEW |