[FIR] Support for EXPOSED_FUNCTION_RETURN_TYPE
This commit is contained in:
committed by
Mikhail Glukhikh
parent
0f16c88dd2
commit
4e577caa99
+9
@@ -0,0 +1,9 @@
|
||||
class A {
|
||||
private class InnerA {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
abstract class B {
|
||||
<!FIR_EXPOSED_FUNCTION_RETURN_TYPE!>fun foo(str: String): A.InnerA<!>
|
||||
}
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
FILE: exposedFunctionReturnType.kt
|
||||
public final class A : R|kotlin/Any| {
|
||||
public constructor(): R|A| {
|
||||
super<R|kotlin/Any|>()
|
||||
}
|
||||
|
||||
private final class InnerA : R|kotlin/Any| {
|
||||
public[private] constructor(): R|A.InnerA| {
|
||||
super<R|kotlin/Any|>()
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
public abstract class B : R|kotlin/Any| {
|
||||
public constructor(): R|B| {
|
||||
super<R|kotlin/Any|>()
|
||||
}
|
||||
|
||||
public final fun foo(str: R|kotlin/String|): R|A.InnerA|
|
||||
|
||||
}
|
||||
|
||||
Generated
+5
@@ -2138,6 +2138,11 @@ public class FirDiagnosticsTestGenerated extends AbstractFirDiagnosticsTest {
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/fir/analysis-tests/testData/resolve/visibility"), Pattern.compile("^([^.]+)\\.kt$"), null, true);
|
||||
}
|
||||
|
||||
@TestMetadata("exposedFunctionReturnType.kt")
|
||||
public void testExposedFunctionReturnType() throws Exception {
|
||||
runTest("compiler/fir/analysis-tests/testData/resolve/visibility/exposedFunctionReturnType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("exposedPropertyType.kt")
|
||||
public void testExposedPropertyType() throws Exception {
|
||||
runTest("compiler/fir/analysis-tests/testData/resolve/visibility/exposedPropertyType.kt");
|
||||
|
||||
+5
@@ -2138,6 +2138,11 @@ public class FirDiagnosticsWithLightTreeTestGenerated extends AbstractFirDiagnos
|
||||
KotlinTestUtils.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/fir/analysis-tests/testData/resolve/visibility"), Pattern.compile("^([^.]+)\\.kt$"), null, true);
|
||||
}
|
||||
|
||||
@TestMetadata("exposedFunctionReturnType.kt")
|
||||
public void testExposedFunctionReturnType() throws Exception {
|
||||
runTest("compiler/fir/analysis-tests/testData/resolve/visibility/exposedFunctionReturnType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("exposedPropertyType.kt")
|
||||
public void testExposedPropertyType() throws Exception {
|
||||
runTest("compiler/fir/analysis-tests/testData/resolve/visibility/exposedPropertyType.kt");
|
||||
|
||||
Reference in New Issue
Block a user