Skip to content

Commit

Permalink
Showing 3 changed files with 3 additions and 37 deletions.
Original file line number Diff line number Diff line change
@@ -57,10 +57,6 @@ public Object interpret(ThreadContext context, StaticScope currScope, DynamicSco
Ruby runtime = context.runtime;
RubyModule clazz = IRRuntimeHelpers.findInstanceMethodContainer(context, currDynScope, self);

//if (clazz != context.getRubyClass()) {
// System.out.println("*** DING DING DING! *** For " + this + "; clazz: " + clazz + "; ruby module: " + context.getRubyClass());
//}

String name = method.getName();
Visibility currVisibility = context.getCurrentVisibility();
Visibility newVisibility = Helpers.performNormalMethodChecksAndDetermineVisibility(runtime, clazz, name, currVisibility);
2 changes: 1 addition & 1 deletion core/src/main/java/org/jruby/runtime/Helpers.java
Original file line number Diff line number Diff line change
@@ -1229,7 +1229,7 @@ public static Block ensureSuperBlock(Block given, Block parent) {
}

public static RubyModule findImplementerIfNecessary(RubyModule clazz, RubyModule implementationClass) {
if (implementationClass != null && implementationClass.needsImplementer()) {
if (implementationClass.needsImplementer()) {
// modules are included with a shim class; we must find that shim to handle super() appropriately
return clazz.findImplementer(implementationClass);
} else {
34 changes: 2 additions & 32 deletions core/src/main/java/org/jruby/runtime/ThreadContext.java
Original file line number Diff line number Diff line change
@@ -835,40 +835,20 @@ public void postBsfApply() {
}

public void preMethodFrameAndClass(RubyModule implClass, String name, IRubyObject self, Block block, StaticScope staticScope) {
RubyModule ssModule = staticScope.getModule();
// FIXME: This is currently only here because of some problems with IOOutputStream writing to a "bare" runtime without a proper scope
if (ssModule == null) ssModule = implClass;
pushCallFrame(implClass, name, self, block);
}

public void preMethodFrameAndScope(RubyModule clazz, String name, IRubyObject self, Block block,
StaticScope staticScope) {
RubyModule implementationClass = staticScope.getModule();
// FIXME: This is currently only here because of some problems with IOOutputStream writing to a "bare" runtime without a proper scope
if (implementationClass == null) {
implementationClass = clazz;
}
public void preMethodFrameAndScope(RubyModule clazz, String name, IRubyObject self, Block block, StaticScope staticScope) {
pushCallFrame(clazz, name, self, block);
pushScope(DynamicScope.newDynamicScope(staticScope));
}

public void preMethodFrameAndDummyScope(RubyModule clazz, String name, IRubyObject self, Block block,
StaticScope staticScope) {
RubyModule implementationClass = staticScope.getModule();
// FIXME: This is currently only here because of some problems with IOOutputStream writing to a "bare" runtime without a proper scope
if (implementationClass == null) {
implementationClass = clazz;
}
public void preMethodFrameAndDummyScope(RubyModule clazz, String name, IRubyObject self, Block block, StaticScope staticScope) {
pushCallFrame(clazz, name, self, block);
pushScope(staticScope.getDummyScope());
}

public void preMethodNoFrameAndDummyScope(RubyModule clazz, StaticScope staticScope) {
RubyModule implementationClass = staticScope.getModule();
// FIXME: This is currently only here because of some problems with IOOutputStream writing to a "bare" runtime without a proper scope
if (implementationClass == null) {
implementationClass = clazz;
}
pushScope(staticScope.getDummyScope());
}

@@ -886,11 +866,6 @@ public void postMethodFrameOnly() {
}

public void preMethodScopeOnly(RubyModule clazz, StaticScope staticScope) {
RubyModule implementationClass = staticScope.getModule();
// FIXME: This is currently only here because of some problems with IOOutputStream writing to a "bare" runtime without a proper scope
if (implementationClass == null) {
implementationClass = clazz;
}
pushScope(DynamicScope.newDynamicScope(staticScope));
}

@@ -910,11 +885,6 @@ public void preMethodBacktraceOnly(String name) {
}

public void preMethodBacktraceDummyScope(RubyModule clazz, String name, StaticScope staticScope) {
RubyModule implementationClass = staticScope.getModule();
// FIXME: This is currently only here because of some problems with IOOutputStream writing to a "bare" runtime without a proper scope
if (implementationClass == null) {
implementationClass = clazz;
}
pushScope(staticScope.getDummyScope());
}

0 comments on commit 3e74923

Please sign in to comment.