kentfredric / ideas

Draft ideas for things that are more organised and feedbacky than gists with mkdn as default
1 stars 0 forks source link

Exception thinger syntax blah #4

Open kentfredric opened 9 years ago

kentfredric commented 9 years ago

package Bar;
use Mexical::Exceptions -define => {
    'Foo' => #     Bar::Foo like MooseX::Types
             #     also defines throw_Foo()
             #     Generic description containing "Foo"
             #    any arguments cached in a %payload
    {

    },
};

blah blah blah:

    throw_Foo(@args),
    my $object = new_Foo(@args); # there's no way you actually need that.