summaryrefslogtreecommitdiff
path: root/regen
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2019-08-29 21:23:20 -0600
committerKarl Williamson <khw@cpan.org>2019-09-02 21:52:10 -0600
commita1a5a9c8b3ceb32212a136f7b42e1889e8500ba8 (patch)
tree5f18d7b9195ff03c5168f93aeab0083be5d02f72 /regen
parentbb3eff5d3d7e45d422801f5cc0f329daf0c4766d (diff)
downloadperl-a1a5a9c8b3ceb32212a136f7b42e1889e8500ba8.tar.gz
Note that the warnings categories are documented
This generates a hidden apidoc entry for the warnings categories, for downstream processing, like Devel::PPPort.
Diffstat (limited to 'regen')
-rw-r--r--regen/warnings.pl10
1 files changed, 8 insertions, 2 deletions
diff --git a/regen/warnings.pl b/regen/warnings.pl
index 56186c5fa0..1c58b3ad0e 100644
--- a/regen/warnings.pl
+++ b/regen/warnings.pl
@@ -358,15 +358,21 @@ EOM
my $k ;
my $last_ver = 0;
+ my @names;
foreach $k (sort { $a <=> $b } keys %ValueToName) {
my ($name, $version) = @{ $ValueToName{$k} };
print $warn "\n/* Warnings Categories added in Perl $version */\n\n"
if $last_ver != $version ;
$name =~ y/:/_/;
- print $warn tab(6, "#define WARN_$name"), " $k\n" ;
+ $name = "WARN_$name";
+ print $warn tab(6, "#define $name"), " $k\n" ;
+ push @names, $name;
$last_ver = $version ;
}
- print $warn "\n" ;
+ print $warn "\n\n/*\n" ;
+
+ print $warn map { "=for apidoc Amnh||$_\n" } @names;
+ print $warn "\n=cut\n*/\n\n" ;
print $warn tab(6, '#define WARNsize'), " $warn_size\n" ;
print $warn tab(6, '#define WARN_ALLstring'), ' "', ('\125' x $warn_size) , "\"\n" ;