Class: Contracts::Nothrows

Inherits:
Base
  • Object
show all
Defined in:
lib/contracts/nothrows.rb

Overview

Author

radiospiel ([email protected])

Copyright

Copyright © 2011, 2012 radiospiel

License

Distributes under the terms of the Modified BSD License, see LICENSE.BSD for details.

++

Instance Attribute Summary

Attributes inherited from Base

#method

Instance Method Summary collapse

Methods inherited from Base

#+@, #method_name

Instance Method Details

#on_exception(_, _rv, _method, _receiver, *_args, &_blk) ⇒ Object



9
10
11
# File 'lib/contracts/nothrows.rb', line 9

def on_exception(_, _rv, _method, _receiver, *_args, &_blk)
  error! "Nothrow method `#{method_name}` raised exception: #{$ERROR_INFO}"
end