<pre><code>package Person;
use Moose;
-with 'HasPermissions';</code></pre>
+with 'Printable';</code></pre>
</div>
<div class="slide">
<h1>Classes Consume Roles</h1>
-<pre><code>my $person = Person->new(
+<pre><code>package Person;
+
+sub as_string { $_[0]->first_name() }
+
+my $person = Person->new(
first_name => 'Kenichi',
last_name => 'Asai',
access_level => 42,
);
-print $person->full_name
- . ' has '
- . $person->can_access(42)
- ? 'great power'
- : 'little power';</code></pre>
+$person->print();</code></pre>
</div>
<div class="slide">