develooper Front page | perl.perl5.porters | Postings from July 2016

Re: Indented here docs?

Thread Previous | Thread Next
July 17, 2016 13:20
Re: Indented here docs?
Message ID:
On Sat, Jul 16, 2016 at 12:49 PM, Sawyer X <> wrote:
> Bare << was deprecated for 20 years now. It has now been a principal
> part of a discussion on a new feature and stood in the way. The fact
> that we ended up picking different syntax which does not mix with bare
> << does not mean it was not in the way. As such, and in any such
> situation[1], it is subject for removal.


> [1] Any feature that has been deprecated for 20 years and has been
> raised as a problem in introducing new syntax.

Perl policy says:

  =item deprecated

  If something in the Perl core is marked as B<deprecated>, we may remove it
  from the core in the future, though we might not.  Generally, backward
  incompatible changes will have deprecation warnings for two release
  cycles before being removed, but may be removed after just one cycle if
  the risk seems quite low or the benefits quite high.

The important part here: "we may remove it from the core in the
future, though we might not".

This says to me we could simply remove the syntax and be done with it,
and still abide by our own policies.

That said, I feel just ripping it out in this release isn't the nicest
thing to do.

We already have a syntax that works even if it's not the most ideal
(<<~), so we don't *need* to rip out bare << now, right?

True, it's been deprecated for 20 years, but it hasn't ever been
removed, and talk of its removal hasn't come up (that I know of) until
now. To me, as a user, I would treat this as "Well it's deprecated,
but it's been deprecated for as long as I've used the language, so
even though I'm using it when I shouldn't, it looks like it won't be
going away any time soon. Why bother fixing my code?"

I think it would be unfair and surprising to rip out the deprecated
syntax in this release without at least 1 release with a notice
stating our intent. This would get us a new feature now, and give
others time to adapt their code. (Would mentioning this in the NOTICE
section of perldelta.pod be enough? Would we modify the warning to say
that the functionality would be going away?)


-- Matthew Horsfall (alh)

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About