Generate bridges for property accessors

Use existing FunctionCodegen.generateBridgeIfNeeded() on property getters &
setters

 #KT-2920 Fixed
This commit is contained in:
Alexander Udalov
2012-10-09 15:57:31 +04:00
parent 7d28ee4342
commit e869568196
7 changed files with 110 additions and 24 deletions
@@ -149,4 +149,29 @@ public class BridgeMethodGenTest extends CodegenTestCase {
createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.JDK_ONLY);
blackBoxFile("regressions/kt2702.kt");
}
public void testKt2920() {
createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.JDK_ONLY);
blackBoxFile("regressions/kt2920.kt");
}
public void testSubstitutionInSuperClassProperty() {
createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.JDK_ONLY);
blackBoxFile("bridges/substitutionInSuperClassProperty.kt");
}
public void testPropertySetter() {
createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.JDK_ONLY);
blackBoxFile("bridges/propertySetter.kt");
}
public void testPropertyDiamond() {
createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.JDK_ONLY);
blackBoxFile("bridges/propertyDiamond.kt");
}
public void testPropertyAccessorsWithoutBody() {
createEnvironmentWithMockJdkAndIdeaAnnotations(ConfigurationKind.JDK_ONLY);
blackBoxFile("bridges/propertyAccessorsWithoutBody.kt");
}
}