Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 09ecd355b151
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 060f5f31bf6f
Choose a head ref
  • 2 commits
  • 2 files changed
  • 1 contributor

Commits on Oct 13, 2015

  1. Copy the full SHA
    8d893fc View commit details
  2. Copy the full SHA
    060f5f3 View commit details
Showing with 4 additions and 6 deletions.
  1. +4 −2 core/src/main/java/org/jruby/RubyModule.java
  2. +0 −4 spec/tags/ruby/core/module/const_defined_tags.txt
6 changes: 4 additions & 2 deletions core/src/main/java/org/jruby/RubyModule.java
Original file line number Diff line number Diff line change
@@ -3063,8 +3063,10 @@ public RubyBoolean const_defined_p19(ThreadContext context, IRubyObject[] args)
if (segment.length() == 0) throw context.runtime.newNameError("wrong constant name " + fullName, symbol);
symbol = symbol.substring(sep + 2);
IRubyObject obj = mod.getConstantNoConstMissing(validateConstant(segment, args[0]), inherit, inherit);
if(obj instanceof RubyModule) {
mod = (RubyModule)obj;
if (obj instanceof RubyModule) {
mod = (RubyModule) obj;
} else if (obj == null) {
return runtime.getFalse();
} else {
throw runtime.newTypeError(segment + " does not refer to class/module");
}
4 changes: 0 additions & 4 deletions spec/tags/ruby/core/module/const_defined_tags.txt

This file was deleted.