{ package Child::Creator; use Moose::Role; requires 'child_context'; sub create_child { 'Child'->new(context => shift->child_context); } } { package Parent; use Moose; with 'Child::Creator'; sub child_context { 'parent' }; __PACKAGE__->meta->make_immutable; } ...