Front page | perl.perl5.porters |
Postings from July 2016
Re: Indented here docs?
July 5, 2016 10:08
Re: Indented here docs?
Message ID: firstname.lastname@example.org
Sawyer X <email@example.com> writes:
> On 07/03/2016 10:31 PM, Dagfinn Ilmari Mannsåker wrote:
>> Father Chrysostomos <firstname.lastname@example.org> writes:
>>> Paul Johnson wrote:
>>>> On Sun, Jul 03, 2016 at 03:28:56PM -0400, Matthew Horsfall (alh) wrote:
>>>>> Aside from the above, do we have a decision/consensus on if we need a
>>>>> deprecation cycle for the existing behaviour of <<-EOF / <<-"EOF" etc?
>>>>> (which, as far as I can tell, is to throw a warning and then
>>>>> eventually fail compilation? Or are there some cases where this is
>>>>> legal somehow?
>>>>> Also, is this going experimental for 5.26?
>>>> I suppose that one option is to have a deprecation cycle in 5.26,
We've had 14 deprecation cycles for using bare << to mean <<"" (5.002 to
5.24), during 7 of which (5.12 to 5.24) it has been issuing a warning by
default. I don't think we need another.
>>>> and also add this as experimental option which would silence those
>>>> deprecation messages.
It would not silence any deprecation messages. It would make one
specific case of previously-deprecated, now-invalid syntax mean
something new, _if_ you opt in.
>>>> Then we might want to relax our rules about two stable releases and
>>>> remove the experimental status in 5.28.
>>> The existing behaviour of <<- is already deprecated. I think we can
>>> go ahead and change it.
>> Just a data point: it's been deprecated since 5.002, i.e. for over 20
>> years. As far as I can tell it's the second-oldest deprecation still in
>> place in toke.c, after comma-less variable lists in formats, which was
>> deprecated in 5.000.
> This point is very convincing. I'm not against adding this as 5.26
> experimental while deprecating fully <<-, as Paul suggests.
The feature is already as "fully deprecated" as it can be, i.e. it
issues an enabled-by-default warning. The next step would be to remove
it, i.e. make it a syntax error.
I do not have a particular opinion on whether it should be experimental
for one or two releases, but the bare << feature should be removed
separately from, and crucially, _before_ (in commit history order, they
can be in the same (dev) relase) the indented here-doc feature.
- Twitter seems more influential [than blogs] in the 'gets reported in
the mainstream press' sense at least. - Matt McLeod
- That'd be because the content of a tweet is easier to condense down
to a mainstream media article. - Calle Dybedahl