Hello.
I’m working on a project that uses the MathCat4J library (GitHub - mwhapples/MathCAT4J: Java bindings for MathCAT library) and I’m obtaining different results with different compilers.
When compiling the following code:
import onl.mdw.mathcat4j.api.MathCat
import onl.mdw.mathcat4j.api.MathCatJni
import onl.mdw.mathcat4j.core.mathCAT
fun main() {
println (mathCAT { (MathCat::getVersion) ()})
}
with the cli compiler I get no errors and everything works.
But when compiling in IDEA I get the error:
Kotlin: No value passed for parameter 'p1'
And when using other methods like
mathCAT { (MathCat::setRulesDir) (dir)}
the IDEA compiling says
Kotlin: Type mismatch: inferred type is String but MathCat was expected
while on cli everything works ok.
I’m working on an Arch Linux system, with openjdk 22.0.2.
The kotlin cli compiler version is 2.0.20, and the version configured in IDEA is also 2.0.20 and it’s using the system jdk (I think).
Does anyboby know why everything works with the cli compiler and does not work in an IDEA project and how it could be solved?
Thanks.