Skip to content
This repository was archived by the owner on Jan 20, 2023. It is now read-only.

Commit 13cfc42

Browse files
committed
バケツジェネレータの初期化方法を修正
1 parent 963e0c8 commit 13cfc42

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/main/kotlin/com/mapk/core/KFunctionForCall.kt

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,8 @@ class KFunctionForCall<T>(internal val function: KFunction<T>, instance: Any? =
2020
// この関数には確実にアクセスするためアクセシビリティ書き換え
2121
function.isAccessible = true
2222

23-
generator = BucketGenerator(
24-
parameters, instance?.let { parameters.first { param -> param.kind == KParameter.Kind.INSTANCE } to it }
25-
)
23+
// パラメータのチェックを済ませてから初期化しないとエラーになる
24+
generator = BucketGenerator(parameters, instance)
2625
}
2726

2827
fun getArgumentBucket(): ArgumentBucket = generator.generate()

0 commit comments

Comments
 (0)