| 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.resolution.members; | 5 library dart2js.resolution.members; |
| 6 | 6 |
| 7 import '../common.dart'; | 7 import '../common.dart'; |
| 8 import '../common/names.dart' show Selectors; | 8 import '../common/names.dart' show Selectors; |
| 9 import '../common/resolution.dart' show Resolution; | 9 import '../common/resolution.dart' show Resolution; |
| 10 import '../compile_time_constants.dart'; | 10 import '../compile_time_constants.dart'; |
| (...skipping 4045 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4056 inConstContext: node.isConst)); | 4056 inConstContext: node.isConst)); |
| 4057 } | 4057 } |
| 4058 | 4058 |
| 4059 ConstructorResult resolveRedirectingFactory(RedirectingFactoryBody node, | 4059 ConstructorResult resolveRedirectingFactory(RedirectingFactoryBody node, |
| 4060 {bool inConstContext: false}) { | 4060 {bool inConstContext: false}) { |
| 4061 return node.accept(new ConstructorResolver(resolution, this, | 4061 return node.accept(new ConstructorResolver(resolution, this, |
| 4062 inConstContext: inConstContext)); | 4062 inConstContext: inConstContext)); |
| 4063 } | 4063 } |
| 4064 | 4064 |
| 4065 DartType resolveTypeAnnotation(TypeAnnotation node, | 4065 DartType resolveTypeAnnotation(TypeAnnotation node, |
| 4066 {bool malformedIsError: false, bool deferredIsMalformed: true}) { | 4066 {bool malformedIsError: false, |
| 4067 bool deferredIsMalformed: true, |
| 4068 bool registerCheckedModeCheck: true}) { |
| 4067 DartType type = typeResolver.resolveTypeAnnotation(this, node, | 4069 DartType type = typeResolver.resolveTypeAnnotation(this, node, |
| 4068 malformedIsError: malformedIsError, | 4070 malformedIsError: malformedIsError, |
| 4069 deferredIsMalformed: deferredIsMalformed); | 4071 deferredIsMalformed: deferredIsMalformed); |
| 4070 if (!type.isDynamic) { | 4072 if (registerCheckedModeCheck && !type.isDynamic) { |
| 4071 registry.registerTypeUse(new TypeUse.checkedModeCheck(type)); | 4073 registry.registerTypeUse(new TypeUse.checkedModeCheck(type)); |
| 4072 } | 4074 } |
| 4073 return type; | 4075 return type; |
| 4074 } | 4076 } |
| 4075 | 4077 |
| 4076 ResolutionResult visitLiteralList(LiteralList node) { | 4078 ResolutionResult visitLiteralList(LiteralList node) { |
| 4077 bool isValidAsConstant = true; | 4079 bool isValidAsConstant = true; |
| 4078 sendIsMemberAccess = false; | 4080 sendIsMemberAccess = false; |
| 4079 | 4081 |
| 4080 NodeList arguments = node.typeArguments; | 4082 NodeList arguments = node.typeArguments; |
| (...skipping 647 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4728 } | 4730 } |
| 4729 return const NoneResult(); | 4731 return const NoneResult(); |
| 4730 } | 4732 } |
| 4731 } | 4733 } |
| 4732 | 4734 |
| 4733 /// Looks up [name] in [scope] and unwraps the result. | 4735 /// Looks up [name] in [scope] and unwraps the result. |
| 4734 Element lookupInScope( | 4736 Element lookupInScope( |
| 4735 DiagnosticReporter reporter, Node node, Scope scope, String name) { | 4737 DiagnosticReporter reporter, Node node, Scope scope, String name) { |
| 4736 return Elements.unwrap(scope.lookup(name), reporter, node); | 4738 return Elements.unwrap(scope.lookup(name), reporter, node); |
| 4737 } | 4739 } |
| OLD | NEW |