| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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.serialization.elements; | 5 library dart2js.serialization.elements; |
| 6 | 6 |
| 7 import '../common.dart'; | 7 import '../common.dart'; |
| 8 import '../common/names.dart'; | 8 import '../common/names.dart'; |
| 9 import '../constants/constructors.dart'; | 9 import '../constants/constructors.dart'; |
| 10 import '../constants/expressions.dart'; | 10 import '../constants/expressions.dart'; |
| (...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 447 encoder.setBool(Key.IS_REDIRECTING, element.isRedirectingGenerative); | 447 encoder.setBool(Key.IS_REDIRECTING, element.isRedirectingGenerative); |
| 448 } | 448 } |
| 449 encoder.setElement(Key.EFFECTIVE_TARGET, element.effectiveTarget); | 449 encoder.setElement(Key.EFFECTIVE_TARGET, element.effectiveTarget); |
| 450 if (kind == SerializedElementKind.REDIRECTING_FACTORY_CONSTRUCTOR) { | 450 if (kind == SerializedElementKind.REDIRECTING_FACTORY_CONSTRUCTOR) { |
| 451 encoder.setType( | 451 encoder.setType( |
| 452 Key.EFFECTIVE_TARGET_TYPE, | 452 Key.EFFECTIVE_TARGET_TYPE, |
| 453 element | 453 element |
| 454 .computeEffectiveTargetType(element.enclosingClass.thisType)); | 454 .computeEffectiveTargetType(element.enclosingClass.thisType)); |
| 455 encoder.setElement(Key.IMMEDIATE_REDIRECTION_TARGET, | 455 encoder.setElement(Key.IMMEDIATE_REDIRECTION_TARGET, |
| 456 element.immediateRedirectionTarget); | 456 element.immediateRedirectionTarget); |
| 457 encoder.setBool(Key.EFFECTIVE_TARGET_IS_MALFORMED, |
| 458 element.isEffectiveTargetMalformed); |
| 457 if (element.redirectionDeferredPrefix != null) { | 459 if (element.redirectionDeferredPrefix != null) { |
| 458 encoder.setElement(Key.PREFIX, element.redirectionDeferredPrefix); | 460 encoder.setElement(Key.PREFIX, element.redirectionDeferredPrefix); |
| 459 } | 461 } |
| 460 } | 462 } |
| 461 } | 463 } |
| 462 } | 464 } |
| 463 } | 465 } |
| 464 | 466 |
| 465 class FieldSerializer implements ElementSerializer { | 467 class FieldSerializer implements ElementSerializer { |
| 466 const FieldSerializer(); | 468 const FieldSerializer(); |
| (...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 844 return new LocalVariableElementZ(decoder); | 846 return new LocalVariableElementZ(decoder); |
| 845 case SerializedElementKind.EXTERNAL_LIBRARY: | 847 case SerializedElementKind.EXTERNAL_LIBRARY: |
| 846 case SerializedElementKind.EXTERNAL_LIBRARY_MEMBER: | 848 case SerializedElementKind.EXTERNAL_LIBRARY_MEMBER: |
| 847 case SerializedElementKind.EXTERNAL_CLASS_MEMBER: | 849 case SerializedElementKind.EXTERNAL_CLASS_MEMBER: |
| 848 case SerializedElementKind.EXTERNAL_CONSTRUCTOR: | 850 case SerializedElementKind.EXTERNAL_CONSTRUCTOR: |
| 849 break; | 851 break; |
| 850 } | 852 } |
| 851 throw new UnsupportedError("Unexpected element kind '${elementKind}."); | 853 throw new UnsupportedError("Unexpected element kind '${elementKind}."); |
| 852 } | 854 } |
| 853 } | 855 } |
| OLD | NEW |