Kotlin code completion does not work for some classes

As you can see for some classes code completion does not work. Both classes are in kotlin. The only difference is that PlaceholderAPI is a maven library and I don’t have a source downloaded. However for all other maven libraries code completion works. I already tried invalidating caches and restarting but nothing helped. This problem appeared after I upgraded the PlaceholderAPI to a new version.

This problem only occurs in kotlin classes. In java classes the code completion works as expected.
So I’m not sure what am I doing wrong.


The error causing library:



Even kotlin compiler throws an error but I don’t understand what’s wrong

The code:
val api = PlaceholderAPI.getInstance()

    api.buildStatic("team_color") { params: PlaceholderParameters, context: Scope<Team, TeamScope>.Context ->

I should probably report it, but on the other hand I need to continue my work so I’m asking here to get some steps how to avoid this error.

Issue for reference: https://youtrack.jetbrains.com/issue/KT-35752