Sha256: e75808b9a916aef6d11c0efc193ef5c127d9d3c651793214c9c95426344b582b

Contents?: true

Size: 268 Bytes

Versions: 7

Compression:

Stored size: 268 Bytes

Contents

require 'interception'
listener = lambda{ |exception, binding|
  puts "raised: #{exception.inspect}"
}

Interception.listen(listener)

begin
  raise "oopsy"
rescue => exception
  puts "rescued: #{exception.inspect}"
end

raise "daisy"

Interception.unlisten(listener)

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
whos_dated_who-0.1.0 vendor/bundle/gems/interception-0.5/examples/example.rb
whos_dated_who-0.0.1 vendor/bundle/gems/interception-0.5/examples/example.rb
interception-0.5 examples/example.rb
interception-0.4 examples/example.rb
interception-0.3 examples/example.rb
interception-0.2 examples/example.rb
interception-0.1 examples/example.rb