Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
more Registry usage/hackery
  • Loading branch information
moritz committed Aug 13, 2012
1 parent f4e236d commit d3024f0
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
14 changes: 14 additions & 0 deletions htmlify.pl
Expand Up @@ -150,6 +150,13 @@ (Bool :$debug, Bool :$typegraph = False)
%names{$name}<routine>.push: "/type/$podname.html#" ~ uri_escape($name);
%routines{$name}.push: $podname => $chunk;
%types<routine>{$name} = "/routine/" ~ uri_escape( $name );
$dr.add-new(
:kind<routine>,
# TODO: determine subkind, ie method/sub
:name($name),
:pod($chunk),
:!pod-is-complete,
);
}
if $tg.types{$podname} -> $t {
$pod.content.push: Pod::Block::Named.new(
Expand Down Expand Up @@ -201,6 +208,13 @@ (Bool :$debug, Bool :$typegraph = False)
}
}
}
$dr.add-new(
:kind<type>,
# TODO: subkind
:$pod,
:pod-is-complete,
:name($podname),
);
spurt "html/$what/$podname.html", p2h($pod);
}

Expand Down
4 changes: 2 additions & 2 deletions lib/Perl6/Documentable/Registry.pm
Expand Up @@ -5,7 +5,7 @@ class Perl6::Documentable::Registry {
has @.documentables;
has Bool $.composed = False;
has %!cache;
has %!grouped-by
has %!grouped-by;
method add-new(*%args) {
die "Cannot add something to a composed registry" if $.composed;
@!documentables.push: Perl6::Documentable.new(|%args);
Expand All @@ -24,6 +24,6 @@ class Perl6::Documentable::Registry {
%!cache{$by}{$d."$by"()}.push: $d;
}
}
%!cache{$by}{$d};
%!cache{$by}{$what};
}
}

0 comments on commit d3024f0

Please sign in to comment.