Skip to content

Instantly share code, notes, and snippets.

@arthurnn
Created March 14, 2014 15:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save arthurnn/9550476 to your computer and use it in GitHub Desktop.
Save arthurnn/9550476 to your computer and use it in GitHub Desktop.
module Z
def all
p "ALL!"
end
end
class Foo
extend Z
end
module M
def all
super
end
end
class Foo
extend M
end
Foo.method(:all).call
@arthurnn
Copy link
Author

output:

test_ruby.rb:12: [BUG] Segmentation fault at 0x00000000000018
ruby 2.1.0p0 (2013-12-25 revision 44422) [x86_64-darwin13.0]

-- Crash Report log information --------------------------------------------
   See Crash Report log file under the one of following:
     * ~/Library/Logs/CrashReporter
     * /Library/Logs/CrashReporter
     * ~/Library/Logs/DiagnosticReports
     * /Library/Logs/DiagnosticReports
   for more details.

-- Control frame information -----------------------------------------------
c:0004 p:0008 s:0011 e:000009 METHOD test_ruby.rb:12 [FINISH]
c:0003 p:---- s:0007 e:000006 CFUNC  :call
c:0002 p:0055 s:0004 E:0019b8 EVAL   test_ruby.rb:21 [FINISH]
c:0001 p:0000 s:0002 E:000dd8 TOP    [FINISH]

test_ruby.rb:21:in `<main>'
test_ruby.rb:21:in `call'
test_ruby.rb:12:in `all'

-- C level backtrace information -------------------------------------------
0   ruby                                0x000000010c52cacb rb_vm_bugreport + 251
1   ruby                                0x000000010c3b34e5 report_bug + 357
2   ruby                                0x000000010c3b380f rb_bug + 207
3   ruby                                0x000000010c4a00af sigsegv + 207
4   libsystem_platform.dylib            0x00007fff893605aa _sigtramp + 26
5   ruby                                0x000000010c514a31 vm_exec_core + 20833
6   ???                                 0x0000000000000000 0x0 + 0

-- Other runtime information -----------------------------------------------

* Loaded script: test_ruby.rb

* Loaded features:

    0 enumerator.so
    1 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/x86_64-darwin13.0/enc/encdb.bundle
    2 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/x86_64-darwin13.0/enc/trans/transdb.bundle
    3 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/x86_64-darwin13.0/rbconfig.rb
    4 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/compatibility.rb
    5 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/defaults.rb
    6 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/deprecate.rb
    7 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/errors.rb
    8 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/version.rb
    9 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/requirement.rb
   10 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/platform.rb
   11 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/basic_specification.rb
   12 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/stub_specification.rb
   13 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/util/stringio.rb
   14 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/specification.rb
   15 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/exceptions.rb
   16 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/core_ext/kernel_gem.rb
   17 thread.rb
   18 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/x86_64-darwin13.0/thread.bundle
   19 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/monitor.rb
   20 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb
   21 /Users/arthurnn/.rbenv/versions/2.1.0/lib/ruby/2.1.0/rubygems.rb

[NOTE]
You may have encountered a bug in the Ruby interpreter or extension libraries.
Bug reports are welcome.
For details: http://www.ruby-lang.org/bugreport.html

Abort trap: 6

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