From b87e355db3009ef14845a63f4dfc034967dee96e Mon Sep 17 00:00:00 2001 From: Akkadius Date: Sun, 1 Jul 2018 19:36:57 -0500 Subject: [PATCH] Add corpse to perl-doc-parser.pl --- utils/scripts/perl-doc-parser.pl | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/utils/scripts/perl-doc-parser.pl b/utils/scripts/perl-doc-parser.pl index 1a3f20d6f..d54e39ebc 100755 --- a/utils/scripts/perl-doc-parser.pl +++ b/utils/scripts/perl-doc-parser.pl @@ -5,6 +5,7 @@ sub usage() { print "Usage:\n"; print " --client - Prints methods for just client class methods\n"; print " --mob - Prints methods for just mob class methods\n"; + print " --corpse - Prints methods for just corpse class methods\n"; print " --all - Prints methods for all classes\n"; exit(1); } @@ -45,7 +46,7 @@ for my $file (@files) { chomp; $line = $_; - if ($line=~/Client::|Mob::/i && $line=~/_croak/i) { + if ($line=~/Client::|Mob::|Corpse::/i && $line=~/_croak/i) { #::: Client export if ($export=~/all|client/i) { @@ -59,6 +60,12 @@ for my $file (@files) { $object_prefix = "\$mob->"; } + #::: Corpse export + if ($export=~/all|corpse/i) { + $split_key = "Corpse::"; + $object_prefix = "\$corpse->"; + } + #::: Split on croak usage @data = split($split_key, $line); $usage = trim($data[1]);