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 /// Implementation of the Dart types hierarchy in 'types.dart' specifically | 5 /// Implementation of the Dart types hierarchy in 'types.dart' specifically |
6 /// tailored to the resolution phase of the compiler. | 6 /// tailored to the resolution phase of the compiler. |
7 | 7 |
8 library resolution_types; | 8 library resolution_types; |
9 | 9 |
10 import 'dart:math' show min; | 10 import 'dart:math' show min; |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 /// is the function type `(String) -> int`. | 89 /// is the function type `(String) -> int`. |
90 ResolutionDartType get unaliased => this; | 90 ResolutionDartType get unaliased => this; |
91 | 91 |
92 /** | 92 /** |
93 * If this type is malformed or a generic type created with the wrong number | 93 * If this type is malformed or a generic type created with the wrong number |
94 * of type arguments then [userProvidedBadType] holds the bad type provided | 94 * of type arguments then [userProvidedBadType] holds the bad type provided |
95 * by the user. | 95 * by the user. |
96 */ | 96 */ |
97 ResolutionDartType get userProvidedBadType => null; | 97 ResolutionDartType get userProvidedBadType => null; |
98 | 98 |
99 /// Is [: true :] if this type has no explict type arguments. | 99 /// Is [: true :] if this type has no explicit type arguments. |
100 bool get isRaw => true; | 100 bool get isRaw => true; |
101 | 101 |
102 /// Returns the raw version of this type. | 102 /// Returns the raw version of this type. |
103 ResolutionDartType asRaw() => this; | 103 ResolutionDartType asRaw() => this; |
104 | 104 |
105 /// Is [: true :] if this type has no non-dynamic type arguments. | 105 /// Is [: true :] if this type has no non-dynamic type arguments. |
106 bool get treatAsRaw => isRaw; | 106 bool get treatAsRaw => isRaw; |
107 | 107 |
108 /// Is [: true :] if this type should be treated as the dynamic type. | 108 /// Is [: true :] if this type should be treated as the dynamic type. |
109 bool get treatAsDynamic => false; | 109 bool get treatAsDynamic => false; |
(...skipping 1720 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1830 sb.write(', '); | 1830 sb.write(', '); |
1831 } | 1831 } |
1832 namedParameterTypes[index].accept(this, namedParameters[index]); | 1832 namedParameterTypes[index].accept(this, namedParameters[index]); |
1833 needsComma = true; | 1833 needsComma = true; |
1834 } | 1834 } |
1835 sb.write('}'); | 1835 sb.write('}'); |
1836 } | 1836 } |
1837 sb.write(')'); | 1837 sb.write(')'); |
1838 } | 1838 } |
1839 } | 1839 } |
OLD | NEW |