Skip to content

Commit

Permalink
Deleted a bunch of dead code
Browse files Browse the repository at this point in the history
  • Loading branch information
subbuss committed Sep 12, 2014
1 parent 99dde7f commit 3e74923
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 37 deletions.
Expand Up @@ -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);
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/java/org/jruby/runtime/Helpers.java
Expand Up @@ -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 {
Expand Down
34 changes: 2 additions & 32 deletions core/src/main/java/org/jruby/runtime/ThreadContext.java
Expand Up @@ -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());
}

Expand All @@ -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));
}

Expand All @@ -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());
}

Expand Down

0 comments on commit 3e74923

Please sign in to comment.