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

Commits on Apr 29, 2016

  1. Remove is2_0 checks.

    headius committed Apr 29, 2016
    Copy the full SHA
    b09a535 View commit details
  2. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    3dc2acf View commit details
  3. Copy the full SHA
    7d74583 View commit details
Showing with 9 additions and 4 deletions.
  1. +8 −3 core/src/main/java/org/jruby/internal/runtime/RubyRunnable.java
  2. +1 −1 core/src/main/java/org/jruby/util/cli/Options.java
11 changes: 8 additions & 3 deletions core/src/main/java/org/jruby/internal/runtime/RubyRunnable.java
Original file line number Diff line number Diff line change
@@ -92,12 +92,17 @@ public void run() {

// uber-ThreadKill catcher, since it should always just mean "be dead"
try {
// Push a frame for the toplevel of the thread

// Call the thread's code
RubyModule frameClass = proc.getBlock().getFrame().getKlazz();
Block threadBlock = proc.getBlock();
RubyModule frameClass = threadBlock.getFrame().getKlazz();
String file = threadBlock.getBinding().getFile();
int line = threadBlock.getBinding().getLine();
try {
if (runtime.hasEventHooks() && runtime.is2_0()) context.trace(RubyEvent.THREAD_BEGIN, null, frameClass);
if (runtime.hasEventHooks()) context.trace(RubyEvent.THREAD_BEGIN, null, frameClass, file, line);
IRubyObject result = proc.call(context, arguments);
if (runtime.hasEventHooks() && runtime.is2_0()) context.trace(RubyEvent.THREAD_END, null, frameClass);
if (runtime.hasEventHooks()) context.trace(RubyEvent.THREAD_END, null, frameClass, file, line);
rubyThread.cleanTerminate(result);
} catch (MainExitException mee) {
// Someone called exit!, so we need to kill the main thread
2 changes: 1 addition & 1 deletion core/src/main/java/org/jruby/util/cli/Options.java
Original file line number Diff line number Diff line change
@@ -218,7 +218,7 @@ public class Options {
public static final Option<String> CLI_BACKUP_EXTENSION = string(CLI, "cli.backup.extension", "Backup extension for in-place ARGV files. Same as -i.");
public static final Option<ProfilingMode> CLI_PROFILING_MODE = enumeration(CLI, "cli.profiling.mode", ProfilingMode.class, ProfilingMode.OFF, "Enable instrumented profiling modes.");
public static final Option<Boolean> CLI_RUBYGEMS_ENABLE = bool(CLI, "cli.rubygems.enable", true, "Enable/disable RubyGems.");
public static final Option<Boolean> CLI_DID_YOU_MEAN_ENABLE = bool(CLI, "cli.did_you_mean.enable", true, "Enable/disable did_you_mean.");
public static final Option<Boolean> CLI_DID_YOU_MEAN_ENABLE = bool(CLI, "cli.did_you_mean.enable", false, "Enable/disable did_you_mean.");
public static final Option<Boolean> CLI_RUBYOPT_ENABLE = bool(CLI, "cli.rubyopt.enable", true, "Enable/disable RUBYOPT processing at start.");
public static final Option<Boolean> CLI_STRIP_HEADER = bool(CLI, "cli.strip.header", false, "Strip text before shebang in script. Same as -x.");
public static final Option<Boolean> CLI_LOAD_GEMFILE = bool(CLI, "cli.load.gemfile", false, "Load a bundler Gemfile in cwd before running. Same as -G.");