Guest User

Untitled

a guest
Jun 17th, 2018
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.38 KB | None | 0 0
  1. package FancyExample;
  2.  
  3. use strict;
  4. use warnings;
  5.  
  6. use base 'Exporter';
  7. our @EXPORT = qw( fancy_death );
  8.  
  9. use Exception::Class::OnCaller ex => {
  10. fields => "data",
  11. description => "This exception has many bells and whistles!",
  12. -as => 'throw',
  13. -subclass => 'BlingError',
  14. };
  15.  
  16. sub fancy_death {
  17. die throw( error => "meep", data => { stuff => 'goes here' } );
  18. }
  19.  
  20. 1;
Add Comment
Please, Sign In to add comment