Skip to content

Commit 6711558

Browse files
committed
Update complier tests
1 parent dd9b00d commit 6711558

14 files changed

+89
-271
lines changed

tests/compiler-plugin-tests/src/testData/box/customParameterTypes.fir.ir.txt

Lines changed: 24 additions & 65 deletions
Large diffs are not rendered by default.

tests/compiler-plugin-tests/src/testData/box/customParameterTypes.fir.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ FILE: customParameterTypes.kt
3737
}
3838

3939
}
40-
@R|kotlinx/rpc/annotations/Rpc|() public abstract interface BoxService : R|kotlinx/rpc/RemoteService| {
40+
@R|kotlinx/rpc/annotations/Rpc|() public abstract interface BoxService : R|kotlin/Any| {
4141
public abstract suspend fun test1(testData: R|TestData|): R|kotlin/String|
4242

4343
public abstract suspend fun test2(testData: R|TestData|): R|kotlin/String|

tests/compiler-plugin-tests/src/testData/box/flowParameter.fir.ir.txt

Lines changed: 14 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
FILE fqName:<root> fileName:/flowParameter.kt
2-
CLASS INTERFACE name:BoxService modality:ABSTRACT visibility:public superTypes:[kotlinx.rpc.RemoteService]
2+
CLASS INTERFACE name:BoxService modality:ABSTRACT visibility:public superTypes:[kotlin.Any]
33
annotations:
44
Rpc
55
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.BoxService
@@ -27,25 +27,6 @@ FILE fqName:<root> fileName:/flowParameter.kt
2727
RETURN type=kotlin.Nothing from='private final fun <get-__rpc_client> (): kotlinx.rpc.RpcClient declared in <root>.BoxService.$rpcServiceStub'
2828
GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:__rpc_client type:kotlinx.rpc.RpcClient visibility:private [final]' type=kotlinx.rpc.RpcClient origin=null
2929
receiver: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.<get-__rpc_client>' type=<root>.BoxService.$rpcServiceStub origin=null
30-
PROPERTY name:coroutineContext visibility:public modality:FINAL [val]
31-
overridden:
32-
public abstract coroutineContext: kotlin.coroutines.CoroutineContext declared in kotlinx.rpc.RpcClient
33-
FIELD PROPERTY_BACKING_FIELD name:coroutineContext type:kotlin.coroutines.CoroutineContext visibility:private [final]
34-
EXPRESSION_BODY
35-
CALL 'public abstract fun provideStubContext (serviceId: kotlin.Long): kotlin.coroutines.CoroutineContext declared in kotlinx.rpc.RpcClient' type=kotlin.coroutines.CoroutineContext origin=null
36-
$this: CALL 'private final fun <get-__rpc_client> (): kotlinx.rpc.RpcClient declared in <root>.BoxService.$rpcServiceStub' type=kotlinx.rpc.RpcClient origin=GET_PROPERTY
37-
$this: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub' type=<root>.BoxService.$rpcServiceStub origin=null
38-
serviceId: CALL 'private final fun <get-__rpc_stub_id> (): kotlin.Long declared in <root>.BoxService.$rpcServiceStub' type=kotlin.Long origin=GET_PROPERTY
39-
$this: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub' type=<root>.BoxService.$rpcServiceStub origin=null
40-
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-coroutineContext> visibility:public modality:FINAL <> ($this:<root>.BoxService.$rpcServiceStub) returnType:kotlin.coroutines.CoroutineContext
41-
correspondingProperty: PROPERTY name:coroutineContext visibility:public modality:FINAL [val]
42-
overridden:
43-
public abstract fun <get-coroutineContext> (): kotlin.coroutines.CoroutineContext declared in <root>.BoxService
44-
$this: VALUE_PARAMETER name:<this> type:<root>.BoxService.$rpcServiceStub
45-
BLOCK_BODY
46-
RETURN type=kotlin.Nothing from='public final fun <get-coroutineContext> (): kotlin.coroutines.CoroutineContext declared in <root>.BoxService.$rpcServiceStub'
47-
GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:coroutineContext type:kotlin.coroutines.CoroutineContext visibility:private [final]' type=kotlin.coroutines.CoroutineContext origin=null
48-
receiver: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.<get-coroutineContext>' type=<root>.BoxService.$rpcServiceStub origin=null
4930
CLASS GENERATED[kotlinx.rpc.codegen.FirRpcServiceStubCompanionObject] OBJECT name:Companion modality:FINAL visibility:public [companion] superTypes:[kotlinx.rpc.descriptor.RpcServiceDescriptor<<root>.BoxService>]
5031
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:<root>.BoxService.$rpcServiceStub.Companion
5132
PROPERTY name:fqName visibility:public modality:FINAL [val]
@@ -525,48 +506,33 @@ FILE fqName:<root> fileName:/flowParameter.kt
525506
VALUE_PARAMETER name:flow index:0 type:kotlinx.coroutines.flow.Flow<kotlin.String>
526507
BLOCK_BODY
527508
RETURN type=kotlin.Nothing from='public open fun stream (flow: kotlinx.coroutines.flow.Flow<kotlin.String>): kotlin.String declared in <root>.BoxService.$rpcServiceStub'
528-
CALL 'public final fun scopedClientCall <T> (serviceScope: kotlinx.coroutines.CoroutineScope, body: kotlin.coroutines.SuspendFunction0<T of kotlinx.rpc.internal.scopedClientCall>): T of kotlinx.rpc.internal.scopedClientCall declared in kotlinx.rpc.internal' type=kotlin.String origin=null
509+
CALL 'public abstract fun call <T> (call: kotlinx.rpc.RpcCall): T of kotlinx.rpc.RpcClient.call declared in kotlinx.rpc.RpcClient' type=kotlin.String origin=null
529510
<T>: kotlin.String
530-
serviceScope: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.stream' type=kotlinx.coroutines.CoroutineScope origin=null
531-
body: FUN_EXPR type=kotlin.coroutines.SuspendFunction0<kotlin.String> origin=LAMBDA
532-
FUN LOCAL_FUNCTION_FOR_LAMBDA name:<anonymous> visibility:local modality:FINAL <> () returnType:kotlin.String [suspend]
533-
BLOCK_BODY
534-
RETURN type=kotlin.Nothing from='local final fun <anonymous> (): kotlin.String declared in <root>.BoxService.$rpcServiceStub.stream'
535-
CALL 'public abstract fun call <T> (call: kotlinx.rpc.RpcCall): T of kotlinx.rpc.RpcClient.call declared in kotlinx.rpc.RpcClient' type=kotlin.String origin=null
536-
<T>: kotlin.String
537-
$this: CALL 'private final fun <get-__rpc_client> (): kotlinx.rpc.RpcClient declared in <root>.BoxService.$rpcServiceStub' type=kotlinx.rpc.RpcClient origin=GET_PROPERTY
538-
$this: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.stream' type=<root>.BoxService.$rpcServiceStub origin=null
539-
call: CONSTRUCTOR_CALL 'public constructor <init> (descriptor: kotlinx.rpc.descriptor.RpcServiceDescriptor<*>, callableName: kotlin.String, data: kotlin.Any, serviceId: kotlin.Long) declared in kotlinx.rpc.RpcCall' type=kotlinx.rpc.RpcCall origin=null
540-
descriptor: GET_OBJECT 'CLASS GENERATED[kotlinx.rpc.codegen.FirRpcServiceStubCompanionObject] OBJECT name:Companion modality:FINAL visibility:public [companion] superTypes:[kotlinx.rpc.descriptor.RpcServiceDescriptor<<root>.BoxService>]' type=<root>.BoxService.$rpcServiceStub.Companion
541-
callableName: CONST String type=kotlin.String value="stream"
542-
data: CONSTRUCTOR_CALL 'public constructor <init> (flow: kotlinx.coroutines.flow.Flow<kotlin.String>) declared in <root>.BoxService.$rpcServiceStub.stream$rpcMethod' type=<root>.BoxService.$rpcServiceStub.stream$rpcMethod origin=null
543-
flow: GET_VAR 'flow: kotlinx.coroutines.flow.Flow<kotlin.String> declared in <root>.BoxService.$rpcServiceStub.stream' type=kotlinx.coroutines.flow.Flow<kotlin.String> origin=null
544-
serviceId: CALL 'private final fun <get-__rpc_stub_id> (): kotlin.Long declared in <root>.BoxService.$rpcServiceStub' type=kotlin.Long origin=GET_PROPERTY
545-
$this: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.stream' type=<root>.BoxService.$rpcServiceStub origin=null
511+
$this: CALL 'private final fun <get-__rpc_client> (): kotlinx.rpc.RpcClient declared in <root>.BoxService.$rpcServiceStub' type=kotlinx.rpc.RpcClient origin=GET_PROPERTY
512+
$this: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.stream' type=<root>.BoxService.$rpcServiceStub origin=null
513+
call: CONSTRUCTOR_CALL 'public constructor <init> (descriptor: kotlinx.rpc.descriptor.RpcServiceDescriptor<*>, callableName: kotlin.String, data: kotlin.Any, serviceId: kotlin.Long) declared in kotlinx.rpc.RpcCall' type=kotlinx.rpc.RpcCall origin=null
514+
descriptor: GET_OBJECT 'CLASS GENERATED[kotlinx.rpc.codegen.FirRpcServiceStubCompanionObject] OBJECT name:Companion modality:FINAL visibility:public [companion] superTypes:[kotlinx.rpc.descriptor.RpcServiceDescriptor<<root>.BoxService>]' type=<root>.BoxService.$rpcServiceStub.Companion
515+
callableName: CONST String type=kotlin.String value="stream"
516+
data: CONSTRUCTOR_CALL 'public constructor <init> (flow: kotlinx.coroutines.flow.Flow<kotlin.String>) declared in <root>.BoxService.$rpcServiceStub.stream$rpcMethod' type=<root>.BoxService.$rpcServiceStub.stream$rpcMethod origin=null
517+
flow: GET_VAR 'flow: kotlinx.coroutines.flow.Flow<kotlin.String> declared in <root>.BoxService.$rpcServiceStub.stream' type=kotlinx.coroutines.flow.Flow<kotlin.String> origin=null
518+
serviceId: CALL 'private final fun <get-__rpc_stub_id> (): kotlin.Long declared in <root>.BoxService.$rpcServiceStub' type=kotlin.Long origin=GET_PROPERTY
519+
$this: GET_VAR '<this>: <root>.BoxService.$rpcServiceStub declared in <root>.BoxService.$rpcServiceStub.stream' type=<root>.BoxService.$rpcServiceStub origin=null
546520
FUN FAKE_OVERRIDE name:equals visibility:public modality:OPEN <> ($this:kotlin.Any, other:kotlin.Any?) returnType:kotlin.Boolean [fake_override,operator]
547521
overridden:
548-
public open fun equals (other: kotlin.Any?): kotlin.Boolean declared in kotlinx.rpc.RemoteService
522+
public open fun equals (other: kotlin.Any?): kotlin.Boolean declared in kotlin.Any
549523
$this: VALUE_PARAMETER name:<this> type:kotlin.Any
550524
VALUE_PARAMETER name:other index:0 type:kotlin.Any?
551525
FUN FAKE_OVERRIDE name:hashCode visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:kotlin.Int [fake_override]
552526
overridden:
553-
public open fun hashCode (): kotlin.Int declared in kotlinx.rpc.RemoteService
527+
public open fun hashCode (): kotlin.Int declared in kotlin.Any
554528
$this: VALUE_PARAMETER name:<this> type:kotlin.Any
555529
FUN FAKE_OVERRIDE name:toString visibility:public modality:OPEN <> ($this:kotlin.Any) returnType:kotlin.String [fake_override]
556530
overridden:
557-
public open fun toString (): kotlin.String declared in kotlinx.rpc.RemoteService
531+
public open fun toString (): kotlin.String declared in kotlin.Any
558532
$this: VALUE_PARAMETER name:<this> type:kotlin.Any
559533
FUN name:stream visibility:public modality:ABSTRACT <> ($this:<root>.BoxService, flow:kotlinx.coroutines.flow.Flow<kotlin.String>) returnType:kotlin.String [suspend]
560534
$this: VALUE_PARAMETER name:<this> type:<root>.BoxService
561535
VALUE_PARAMETER name:flow index:0 type:kotlinx.coroutines.flow.Flow<kotlin.String>
562-
PROPERTY FAKE_OVERRIDE name:coroutineContext visibility:public modality:ABSTRACT [fake_override,val]
563-
overridden:
564-
public abstract coroutineContext: kotlin.coroutines.CoroutineContext declared in kotlinx.rpc.RemoteService
565-
FUN FAKE_OVERRIDE name:<get-coroutineContext> visibility:public modality:ABSTRACT <> ($this:kotlinx.rpc.RemoteService) returnType:kotlin.coroutines.CoroutineContext [fake_override]
566-
correspondingProperty: PROPERTY FAKE_OVERRIDE name:coroutineContext visibility:public modality:ABSTRACT [fake_override,val]
567-
overridden:
568-
public abstract fun <get-coroutineContext> (): kotlin.coroutines.CoroutineContext declared in kotlinx.rpc.RemoteService
569-
$this: VALUE_PARAMETER name:<this> type:kotlinx.rpc.RemoteService
570536
FUN name:box visibility:public modality:FINAL <> () returnType:kotlin.String
571537
BLOCK_BODY
572538
RETURN type=kotlin.Nothing from='public final fun box (): kotlin.String declared in <root>'

tests/compiler-plugin-tests/src/testData/box/flowParameter.fir.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
FILE: flowParameter.kt
2-
@R|kotlinx/rpc/annotations/Rpc|() public abstract interface BoxService : R|kotlinx/rpc/RemoteService| {
2+
@R|kotlinx/rpc/annotations/Rpc|() public abstract interface BoxService : R|kotlin/Any| {
33
public abstract suspend fun stream(flow: R|kotlinx/coroutines/flow/Flow<kotlin/String>|): R|kotlin/String|
44

55
public final class $rpcServiceStub : R|kotlin/Any| {

0 commit comments

Comments
 (0)