Module: MiscHacks::ExceptionMixin
- Defined in:
- lib/mischacks.rb
Instance Method Summary collapse
Instance Method Details
#to_formatted_string ⇒ Object
144 145 146 147 148 149 150 151 |
# File 'lib/mischacks.rb', line 144 def to_formatted_string bt = backtrace.dup head = bt.shift ( ["#{head}: #{self} (#{self.class})"] + bt.map do |l| "\tfrom #{l}" end ).map do |l| "#{l}\n" end.join end |