private Script tryCompile(Node node, String cachedClassName, JRubyClassLoader classLoader, boolean dump) {
if (config.getCompileMode() == CompileMode.FORCEIR) {
final IRScope scope = IRBuilder.createIRBuilder(getIRManager(), is1_9()).buildRoot((RootNode) node);
final Class compiled = JVMVisitor.compile(this, scope, classLoader);
final StaticScope staticScope = scope.getStaticScope();
staticScope.setModule(getTopSelf().getMetaClass());
return new AbstractScript() {
public IRubyObject __file__(ThreadContext context, IRubyObject self, IRubyObject[] args, Block block) {
try {
return (IRubyObject)compiled.getMethod("__script__0", ThreadContext.class, StaticScope.class, IRubyObject.class, Block.class).invoke(null, getCurrentContext(), scope.getStaticScope(), getTopSelf(), block);
} catch (InvocationTargetException ite) {