Permalink
Browse files

CeylonModuleLoader: put back the bit that loaded the langauge module …

…first

Otherwise it's just never initialised
  • Loading branch information...
1 parent 1446aaf commit c96dd0594c7e2f0a76e2e25a97a07a6f1c10a2d1 @FroMage FroMage committed Feb 21, 2013
@@ -53,6 +53,7 @@ public ClassLoader createClassLoader(String name, String version, Configuration
throw cre;
}
try {
+ moduleLoader.setupRuntimeModuleSystem();
Module module = moduleLoader.loadModule(moduleIdentifier);
return SecurityActions.getClassLoader(module);
} catch (ModuleNotFoundException e) {
@@ -343,4 +343,10 @@ static ModuleIdentifier createModuleIdentifier(ArtifactResult i) {
public String toString() {
return "Ceylon ModuleLoader: " + repository;
}
+
+ public void setupRuntimeModuleSystem() throws ModuleLoadException {
+ org.jboss.modules.Module languageModule = org.jboss.modules.Module.getBootModuleLoader().loadModule(LANGUAGE);
+ ArtifactResult languageModuleArtifactResult = findArtifact(LANGUAGE);
+ com.redhat.ceylon.compiler.java.Util.loadModule(LANGUAGE.getName(), LANGUAGE.getSlot(), languageModuleArtifactResult, SecurityActions.getClassLoader(languageModule));
+ }
}

0 comments on commit c96dd05

Please sign in to comment.