Skip to content

Instantly share code, notes, and snippets.

@banister
Created September 6, 2011 06:02
Show Gist options
  • Save banister/1196714 to your computer and use it in GitHub Desktop.
Save banister/1196714 to your computer and use it in GitHub Desktop.
method(:foo).to_java.source_location(org.jruby.Ruby.getGlobalRuntime().getCurrentContext())
@banister
Copy link
Author

banister commented Sep 6, 2011

more robust approach is:

method(:foo).to_java.source_location(Thread.current.to_java.getContext())

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment