Skip to content

Commit d3024f0

Browse files
committed
more Registry usage/hackery
1 parent f4e236d commit d3024f0

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

htmlify.pl

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,13 @@ (Bool :$debug, Bool :$typegraph = False)
150150
%names{$name}<routine>.push: "/type/$podname.html#" ~ uri_escape($name);
151151
%routines{$name}.push: $podname => $chunk;
152152
%types<routine>{$name} = "/routine/" ~ uri_escape( $name );
153+
$dr.add-new(
154+
:kind<routine>,
155+
# TODO: determine subkind, ie method/sub
156+
:name($name),
157+
:pod($chunk),
158+
:!pod-is-complete,
159+
);
153160
}
154161
if $tg.types{$podname} -> $t {
155162
$pod.content.push: Pod::Block::Named.new(
@@ -201,6 +208,13 @@ (Bool :$debug, Bool :$typegraph = False)
201208
}
202209
}
203210
}
211+
$dr.add-new(
212+
:kind<type>,
213+
# TODO: subkind
214+
:$pod,
215+
:pod-is-complete,
216+
:name($podname),
217+
);
204218
spurt "html/$what/$podname.html", p2h($pod);
205219
}
206220

lib/Perl6/Documentable/Registry.pm

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ class Perl6::Documentable::Registry {
55
has @.documentables;
66
has Bool $.composed = False;
77
has %!cache;
8-
has %!grouped-by
8+
has %!grouped-by;
99
method add-new(*%args) {
1010
die "Cannot add something to a composed registry" if $.composed;
1111
@!documentables.push: Perl6::Documentable.new(|%args);
@@ -24,6 +24,6 @@ class Perl6::Documentable::Registry {
2424
%!cache{$by}{$d."$by"()}.push: $d;
2525
}
2626
}
27-
%!cache{$by}{$d};
27+
%!cache{$by}{$what};
2828
}
2929
}

0 commit comments

Comments
 (0)