We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9e98885 commit 1e4ad0cCopy full SHA for 1e4ad0c
lib/Perl6/TypeGraph.pm
@@ -69,9 +69,13 @@ class Perl6::TypeGraph {
69
}
70
for %.types.values -> $t {
71
# roles that have a superclass actually apply that superclass
72
- # to the class that does them, so mimic that here:
73
- for $t.roles -> $r {
+ # to the class that does them, so mimic that here, including
+ # parent roles
74
+ my @roles = $t.roles;
75
+ while @roles {
76
+ my $r = @roles.shift;
77
$t.super.append: $r.super if $r.super;
78
+ @roles.append: $r.roles if $r.roles;
79
80
# non-roles default to superclass Any
81
if $t.packagetype ne 'role' && !$t.super && $t ne 'Mu' {
0 commit comments