kotlin-playground
kotlin-playground copied to clipboard
"No main method found in project" with main method actually present
- This snippet works fine: https://pl.kotl.in/JCOc0ANsA (expected timeout failure)
- This snippet (only different by one line that has nothing to do with function declarations) fails with "No main method found in project": https://pl.kotl.in/wqDvYaWA5
Exception message:
Exception in thread "main" java.lang.IllegalArgumentException: No main method found in project
at com.compiler.server.compiler.components.KotlinCompiler.run$lambda$3 (KotlinCompiler.kt:67)
at com.compiler.server.compiler.components.KotlinCompiler.execute$lambda$16 (KotlinCompiler.kt:148)
at com.compiler.server.compiler.components.CliUtilsKt.usingTempDirectory (CliUtils.kt:119)
- Switching to other compiler versions, both higher and lower, doesn't help
- Adding
args: Array<String>to themainarguments doesnt help