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 // This code was auto-generated, is not intended to be edited, and is subject to | 5 // This code was auto-generated, is not intended to be edited, and is subject to |
6 // significant change. Please see the README file for more information. | 6 // significant change. Please see the README file for more information. |
7 | 7 |
8 library engine.constant; | 8 library engine.constant; |
9 | 9 |
10 import 'dart:collection'; | 10 import 'dart:collection'; |
(...skipping 4988 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4999 ConstructorElement constructor = | 4999 ConstructorElement constructor = |
5000 ConstantEvaluationEngine._getConstructorBase(node.staticElement); | 5000 ConstantEvaluationEngine._getConstructorBase(node.staticElement); |
5001 if (constructor != null) { | 5001 if (constructor != null) { |
5002 _callback(constructor); | 5002 _callback(constructor); |
5003 } | 5003 } |
5004 } | 5004 } |
5005 return super.visitInstanceCreationExpression(node); | 5005 return super.visitInstanceCreationExpression(node); |
5006 } | 5006 } |
5007 | 5007 |
5008 @override | 5008 @override |
| 5009 Object visitLabel(Label node) { |
| 5010 // We are visiting the "label" part of a named expression in a function |
| 5011 // call (presumably a constructor call), e.g. "const C(label: ...)". We |
| 5012 // don't want to visit the SimpleIdentifier for the label because that's a |
| 5013 // reference to a function parameter that needs to be filled in; it's not a |
| 5014 // constant whose value we depend on. |
| 5015 return null; |
| 5016 } |
| 5017 |
| 5018 @override |
5009 Object visitRedirectingConstructorInvocation( | 5019 Object visitRedirectingConstructorInvocation( |
5010 RedirectingConstructorInvocation node) { | 5020 RedirectingConstructorInvocation node) { |
5011 super.visitRedirectingConstructorInvocation(node); | 5021 super.visitRedirectingConstructorInvocation(node); |
5012 ConstructorElement target = | 5022 ConstructorElement target = |
5013 ConstantEvaluationEngine._getConstructorBase(node.staticElement); | 5023 ConstantEvaluationEngine._getConstructorBase(node.staticElement); |
5014 if (target != null) { | 5024 if (target != null) { |
5015 _callback(target); | 5025 _callback(target); |
5016 } | 5026 } |
5017 return null; | 5027 return null; |
5018 } | 5028 } |
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5250 return BoolState.from(_element == rightElement); | 5260 return BoolState.from(_element == rightElement); |
5251 } else if (rightOperand is DynamicState) { | 5261 } else if (rightOperand is DynamicState) { |
5252 return BoolState.UNKNOWN_VALUE; | 5262 return BoolState.UNKNOWN_VALUE; |
5253 } | 5263 } |
5254 return BoolState.FALSE_STATE; | 5264 return BoolState.FALSE_STATE; |
5255 } | 5265 } |
5256 | 5266 |
5257 @override | 5267 @override |
5258 String toString() => _element == null ? "-unknown-" : _element.name; | 5268 String toString() => _element == null ? "-unknown-" : _element.name; |
5259 } | 5269 } |
OLD | NEW |