Help for this page

Select Code to Download


  1. or download this
    use strict; use warnings; use feature 'say';
    use Role::Tiny;
    ...
    my $o = MyClass->new;
    Role::Tiny->apply_roles_to_object($o, 'MyRole');
    say ref($o);
    
  2. or download this
    MyClass__WITH__MyRole