[Native] Always cast expression to the expected type after inline
Right now, during the process of inlining, the compiler erases types. Because of that, we can end up with some random type (for example, `Any`) where the concrete type was expected (for example, `Int`). Compiler must insert a cast in the required places. #KT-66017 Fixed
This commit is contained in:
+15
@@ -20683,11 +20683,26 @@ public class LightAnalysisModeTestGenerated extends AbstractLightAnalysisModeTes
|
||||
runTest("compiler/testData/codegen/box/inline/inlineCtor.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("inlinedLambdaWithErasedParamType.kt")
|
||||
public void testInlinedLambdaWithErasedParamType() {
|
||||
runTest("compiler/testData/codegen/box/inline/inlinedLambdaWithErasedParamType.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("innerInlineFunCapturesOuter.kt")
|
||||
public void testInnerInlineFunCapturesOuter() {
|
||||
runTest("compiler/testData/codegen/box/inline/innerInlineFunCapturesOuter.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt66017.kt")
|
||||
public void testKt66017() {
|
||||
runTest("compiler/testData/codegen/box/inline/kt66017.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("kt66017_inlineFromTheSameModule.kt")
|
||||
public void testKt66017_inlineFromTheSameModule() {
|
||||
runTest("compiler/testData/codegen/box/inline/kt66017_inlineFromTheSameModule.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("lambdaAsAny.kt")
|
||||
public void testLambdaAsAny() {
|
||||
runTest("compiler/testData/codegen/box/inline/lambdaAsAny.kt");
|
||||
|
||||
Reference in New Issue
Block a user