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'; |
11 | 11 |
12 import 'ast.dart'; | 12 import 'ast.dart'; |
13 import 'element.dart'; | 13 import 'element.dart'; |
14 import 'engine.dart' show AnalysisEngine, RecordingErrorListener; | 14 import 'engine.dart' show AnalysisEngine, RecordingErrorListener; |
15 import 'error.dart'; | 15 import 'error.dart'; |
16 import 'java_core.dart'; | 16 import 'java_core.dart'; |
17 import 'java_engine.dart' show ObjectUtilities; | |
18 import 'resolver.dart' show TypeProvider; | 17 import 'resolver.dart' show TypeProvider; |
19 import 'scanner.dart' show Token, TokenType; | 18 import 'scanner.dart' show Token, TokenType; |
20 import 'source.dart' show Source; | 19 import 'source.dart' show Source; |
21 import 'utilities_collection.dart'; | 20 import 'utilities_collection.dart'; |
22 import 'utilities_dart.dart' show ParameterKind; | 21 import 'utilities_dart.dart' show ParameterKind; |
| 22 import 'package:analyzer/src/generated/utilities_general.dart'; |
23 | 23 |
24 /** | 24 /** |
25 * Instances of the class `BoolState` represent the state of an object represent
ing a boolean | 25 * Instances of the class `BoolState` represent the state of an object represent
ing a boolean |
26 * value. | 26 * value. |
27 */ | 27 */ |
28 class BoolState extends InstanceState { | 28 class BoolState extends InstanceState { |
29 /** | 29 /** |
30 * An instance representing the boolean value 'false'. | 30 * An instance representing the boolean value 'false'. |
31 */ | 31 */ |
32 static BoolState FALSE_STATE = new BoolState(false); | 32 static BoolState FALSE_STATE = new BoolState(false); |
(...skipping 2170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2203 } | 2203 } |
2204 return null; | 2204 return null; |
2205 } | 2205 } |
2206 | 2206 |
2207 HashMap<String, DartObjectImpl> get fields => _state.fields; | 2207 HashMap<String, DartObjectImpl> get fields => _state.fields; |
2208 | 2208 |
2209 @override | 2209 @override |
2210 bool get hasExactValue => _state.hasExactValue; | 2210 bool get hasExactValue => _state.hasExactValue; |
2211 | 2211 |
2212 @override | 2212 @override |
2213 int get hashCode => | 2213 int get hashCode => JenkinsSmiHash.hash2(type.hashCode, _state.hashCode); |
2214 ObjectUtilities.combineHashCodes(type.hashCode, _state.hashCode); | |
2215 | 2214 |
2216 @override | 2215 @override |
2217 int get intValue { | 2216 int get intValue { |
2218 if (_state is IntState) { | 2217 if (_state is IntState) { |
2219 return (_state as IntState).value; | 2218 return (_state as IntState).value; |
2220 } | 2219 } |
2221 return null; | 2220 return null; |
2222 } | 2221 } |
2223 | 2222 |
2224 /** | 2223 /** |
(...skipping 2962 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5187 return BoolState.from(_element == rightElement); | 5186 return BoolState.from(_element == rightElement); |
5188 } else if (rightOperand is DynamicState) { | 5187 } else if (rightOperand is DynamicState) { |
5189 return BoolState.UNKNOWN_VALUE; | 5188 return BoolState.UNKNOWN_VALUE; |
5190 } | 5189 } |
5191 return BoolState.FALSE_STATE; | 5190 return BoolState.FALSE_STATE; |
5192 } | 5191 } |
5193 | 5192 |
5194 @override | 5193 @override |
5195 String toString() => _element == null ? "-unknown-" : _element.name; | 5194 String toString() => _element == null ? "-unknown-" : _element.name; |
5196 } | 5195 } |
OLD | NEW |