Implement context classpath extraction using particular class,...
Use it in the main-kts. Also improve diagnoistics related to the definition loading. #KT-26828 fixed (after this commit - finally, see also another related commit)
This commit is contained in:
+1
-1
@@ -60,7 +60,7 @@ fun createCompilationConfigurationFromTemplate(
|
||||
fun scriptConfigInstance(kclass: KClass<out ScriptCompilationConfiguration>): ScriptCompilationConfiguration = try {
|
||||
kclass.objectInstance ?: kclass.createInstance()
|
||||
} catch (e: Throwable) {
|
||||
throw IllegalArgumentException(ILLEGAL_CONFIG_ANN_ARG, e)
|
||||
throw IllegalArgumentException("$ILLEGAL_CONFIG_ANN_ARG: ${e.message}", e)
|
||||
}
|
||||
|
||||
return ScriptCompilationConfiguration(scriptConfigInstance(mainAnnotation.compilationConfiguration)) {
|
||||
|
||||
Reference in New Issue
Block a user