develooper Front page | perl.perl5.porters | Postings from August 2021

Re: "use v5.36.0" should imply ASCII source

Thread Previous | Thread Next
From:
Dan Book
Date:
August 7, 2021 15:56
Subject:
Re: "use v5.36.0" should imply ASCII source
Message ID:
CABMkAVXkMCH9D4OVOmJosKB1Q7PDNxom0CRjTqwR4Jf1Y9+gYw@mail.gmail.com
On Sat, Aug 7, 2021 at 2:45 AM Darren Duncan <darren@darrenduncan.net>
wrote:

> On 2021-08-06 5:01 p.m., Chris Prather wrote:
> >> On Aug 6, 2021, at 2:58 PM, Dan Book <grinnz@gmail.com> wrote:
> >>
> >> I don't think it's comparable. Comments are parsed by the perl
> interpreter, but POD is not, except to find the end of the POD.
> >
> > Additionally comments don’t as far as I know have a way to declare their
> encoding.
>
> Question:  Is there ever a real life scenario where a single source file
> is not
> entirely the same encoding?  Can you reasonably have a single file
> containing
> Perl code and POD where the Perl code is one character encoding and the
> POD is
> another one? -- Darren Duncan
>

Yes. POD parsers and the perl interpreter do not read the same parts of the
file, ever. Thus they must each indicate to their corresponding parsers
what encoding they contain.

-Dan

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About