Skip to content

Instantly share code, notes, and snippets.

@wilson
Created September 18, 2008 15:04
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 wilson/11436 to your computer and use it in GitHub Desktop.
Save wilson/11436 to your computer and use it in GitHub Desktop.
An exception has occurred:
No method 'call' on an instance of Fixnum. (NoMethodError)
Backtrace:
Kernel(Fixnum)#method_missing at kernel/delta/kernel.rb:13
Object#with_block at bp.rb:2
main.__script__ at bp.rb:5
CompiledMethod#activate_as_script at kernel/common/compiled_method.rb:230
CompiledMethod#as_script at kernel/common/compiled_method.rb:223
Compile.single_load at kernel/common/compile.rb:264
Compile.load_from_extension at kernel/common/compile.rb:309
Object#__script__ at kernel/loader.rb:257
> cat bp.rb
def with_block(&prc)
prc.call(1) # If you inspect prc here, it is a Proc, but..
end
with_block do |z|
STDERR.puts z
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment