diff --git a/plugins/groovy/groovy-psi/src/org/jetbrains/plugins/groovy/dsl/GroovyDslExecutor.groovy b/plugins/groovy/groovy-psi/src/org/jetbrains/plugins/groovy/dsl/GroovyDslExecutor.groovy index 5743a2e60388..27202b68cc67 100644 --- a/plugins/groovy/groovy-psi/src/org/jetbrains/plugins/groovy/dsl/GroovyDslExecutor.groovy +++ b/plugins/groovy/groovy-psi/src/org/jetbrains/plugins/groovy/dsl/GroovyDslExecutor.groovy @@ -146,7 +146,7 @@ abstract class GroovyDslExecutor extends Script implements GdslScopeMethods, Gds public static GroovyDslExecutor createAndRunExecutor(String text, String fileName) { def configuration = new CompilerConfiguration() configuration.scriptBaseClass = GroovyDslExecutor.name - def shell = new GroovyShell(configuration) + def shell = new GroovyShell(GroovyDslExecutor.classLoader, configuration) def script = shell.parse(text, StringUtil.sanitizeJavaIdentifier(fileName)) as GroovyDslExecutor script.fileName = fileName script.run()