An error occurred while calling the LowLevelKeyboardProc function.
Announced in the ‘.h’ file, created ‘.klib’ with the help of ‘cinterop’. But there is an error.
LRESULT CALLBACK LowLevelKeyboardProc(
In int nCode,
In WPARAM wParam,
In LPARAM lParam
);
main.kt:15:46: error: no value passed for parameter ‘nCode’
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:46: error: no value passed for parameter ‘wParam’
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:46: error: type mismatch: inferred type is LRESULT /* = Long / but HOOKPROC? / = CPointer<CFunction<(Int, WPARAM /* = ULong /, LPARAM / = Long /) → LRESULT / = Long />>? / was expected
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:67: error: type mismatch: inferred type is (???, ???, ???) → Unit but LPARAM / = Long / was expected
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:69: error: cannot infer a type for this parameter. Please specify it explicitly.
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:76: error: cannot infer a type for this parameter. Please specify it explicitly.
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:84: error: cannot infer a type for this parameter. Please specify it explicitly.
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)
^
main.kt:15:116: error: type mismatch: inferred type is CPointer<CFunction<(LPCWSTR? / = CPointer<WCHARVar / = UShortVarOf<WCHAR /* = UShort */> */>? /) → HMODULE? / = CPointer<HINSTANCE__>? />>? but HINSTANCE? / = CPointer<HINSTANCE__>? */ was expected
hhk = SetWindowsHookExA(WH_KEYBOARD_LL, (LowLevelKeyboardProc { nCode, wParam, info → println(info.vkCode)}), hMod, 0)