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: e8dfcb420149
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 77a9ccee2078
Choose a head ref
  • 7 commits
  • 4 files changed
  • 1 contributor

Commits on Apr 11, 2018

  1. Copy the full SHA
    3e338f6 View commit details
  2. Copy the full SHA
    5499c95 View commit details
  3. Copy the full SHA
    3c10146 View commit details
  4. Copy the full SHA
    31be583 View commit details
  5. Copy the full SHA
    e6fc8da View commit details
  6. Copy the full SHA
    e31af32 View commit details
  7. Copy the full SHA
    77a9cce View commit details
10 changes: 9 additions & 1 deletion core/src/main/java/org/jruby/RubyFloat.java
Original file line number Diff line number Diff line change
@@ -1117,7 +1117,11 @@ else if (d == 0.5 || ((double)((f - 0.5) / s) >= x))
*/
@JRubyMethod(name = "nan?")
public IRubyObject nan_p() {
return RubyBoolean.newBoolean(getRuntime(), Double.isNaN(value));
return RubyBoolean.newBoolean(getRuntime(), isNaN());
}

public boolean isNaN() {
return Double.isNaN(value);
}

/** flo_is_infinite_p
@@ -1131,6 +1135,10 @@ public IRubyObject infinite_p() {
return getRuntime().getNil();
}

public boolean isInfinite() {
return Double.isInfinite(value);
}

/** flo_is_finite_p
*
*/
Loading