Skip to content
Browse files

Make it compatibile with the new --doc=foo behaviour

  • Loading branch information...
1 parent dd7b8dc commit 73877b2e585502f6400047c6a8c20c4348a25647 @tadzik tadzik committed Apr 21, 2012
Showing with 5 additions and 6 deletions.
  1. +5 −6 lib/Pod/To/HTML.pm
View
11 lib/Pod/To/HTML.pm
@@ -1,6 +1,10 @@
-module Pod::To::HTML;
+class Pod::To::HTML;
use Text::Escape;
+method render($pod) {
+ pod2html($pod)
+}
+
# FIXME: this code's a horrible mess. It'd be really helpful to have a module providing a generic
# way to walk a Pod tree and invoke callbacks on each node, that would reduce the multispaghetti at
# the bottom to something much more readable.
@@ -381,8 +385,3 @@ multi sub node2rawtext(Positional $node) returns Str {
multi sub node2rawtext(Str $node) returns Str {
return $node;
}
-
-DOC INIT {
- say pod2html($=POD);
- exit;
-}

0 comments on commit 73877b2

Please sign in to comment.
Something went wrong with that request. Please try again.