Commit Graph
2 Commits
Author SHA1 Message Date
silby 806dcb0849 Consume blanks after =encoding in pod reader (#10544)
The reader did not properly consume empty lines after =encoding commands,
which produced various incorrect parses depending on the content between
there and the next command.

Fixes #10537
2025-01-15 12:07:26 -08:00
Evan Silberman c4716d41c5 Add Pod reader
Pod ("Plain old documentation") is a markup languaged used principally
to document Perl modules and programs. Since it was originally meant to
be translated pretty directly to man, the semantics are fairly simple.

This Pod reader was developed with reference to the canonical user and
implementer documentation of Pod: https://perldoc.perl.org/perlpod and
https://perldoc.perl.org/perlpodspec.

There are 1490 .pod, .pl, and .pm in the Perl 5.34 distribution found in
/System/Library/Perl on my mac. Of those, this reader dies with a parse
error on 7 of them. All of them seem to be cases where pod commands are
found within a non-colon-prefixed =begin/=end. perlpodspec says I may
treat this as an error.

[API change] adds readPod
2024-12-27 11:10:48 -08:00