| 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 part of resolution; | 5 part of resolution; |
| 6 | 6 |
| 7 abstract class TreeElements { | 7 abstract class TreeElements { |
| 8 Element operator[](Node node); | 8 Element operator[](Node node); |
| 9 Selector getSelector(Send send); | 9 Selector getSelector(Send send); |
| 10 Selector getGetterSelectorInComplexSendSet(SendSet node); | 10 Selector getGetterSelectorInComplexSendSet(SendSet node); |
| (...skipping 1391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1402 return e; | 1402 return e; |
| 1403 } | 1403 } |
| 1404 } else { | 1404 } else { |
| 1405 // The caller creates the ErroneousElement for the MalformedType. | 1405 // The caller creates the ErroneousElement for the MalformedType. |
| 1406 return null; | 1406 return null; |
| 1407 } | 1407 } |
| 1408 } else { | 1408 } else { |
| 1409 String stringValue = typeName.source.stringValue; | 1409 String stringValue = typeName.source.stringValue; |
| 1410 if (identical(stringValue, 'void')) { | 1410 if (identical(stringValue, 'void')) { |
| 1411 return compiler.types.voidType.element; | 1411 return compiler.types.voidType.element; |
| 1412 } else if (identical(stringValue, 'Dynamic')) { | |
| 1413 // TODO(aprelev@gmail.com): Remove deprecated Dynamic keyword support. | |
| 1414 compiler.onDeprecatedFeature(typeName, 'Dynamic'); | |
| 1415 return compiler.dynamicClass; | |
| 1416 } else if (identical(stringValue, 'dynamic')) { | 1412 } else if (identical(stringValue, 'dynamic')) { |
| 1417 return compiler.dynamicClass; | 1413 return compiler.dynamicClass; |
| 1418 } else { | 1414 } else { |
| 1419 return scope.lookup(typeName.source); | 1415 return scope.lookup(typeName.source); |
| 1420 } | 1416 } |
| 1421 } | 1417 } |
| 1422 } | 1418 } |
| 1423 | 1419 |
| 1424 // TODO(johnniwinther): Change [onFailure] and [whenResolved] to use boolean | 1420 // TODO(johnniwinther): Change [onFailure] and [whenResolved] to use boolean |
| 1425 // flags instead of closures. | 1421 // flags instead of closures. |
| (...skipping 2394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3820 return e; | 3816 return e; |
| 3821 } | 3817 } |
| 3822 | 3818 |
| 3823 /// Assumed to be called by [resolveRedirectingFactory]. | 3819 /// Assumed to be called by [resolveRedirectingFactory]. |
| 3824 Element visitReturn(Return node) { | 3820 Element visitReturn(Return node) { |
| 3825 Node expression = node.expression; | 3821 Node expression = node.expression; |
| 3826 return finishConstructorReference(visit(expression), | 3822 return finishConstructorReference(visit(expression), |
| 3827 expression, expression); | 3823 expression, expression); |
| 3828 } | 3824 } |
| 3829 } | 3825 } |
| OLD | NEW |