in reply to Re^3: Escaping special characters for POD output
in thread Escaping special characters for POD output
Should have known I was missing things.
The module doesn't escape «>» which is significant when generating the content of tags.
my $s = '$a <=> $b'; my $pod = "C<" . pod_quote($s) . ">"; # Fails
The modules doesn't escape «/» and «"» which are significant when generating the content of L<> tags.
my $s = 'Module for This/That'; my $pod = "L<" . pod_quote($s) . "|Some::Module>"; # Fails
Creating a hash with the replacements should be faster than what you're using now.
Note that «<» only requires escaping when preceded by an ASCII capital letter.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Escaping special characters for POD output
by perlancar (Hermit) on Dec 16, 2019 at 02:48 UTC | |
by ikegami (Patriarch) on Dec 16, 2019 at 11:47 UTC | |
by perlancar (Hermit) on Dec 16, 2019 at 16:15 UTC | |
by ikegami (Patriarch) on Dec 16, 2019 at 17:07 UTC |