Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

die & warn documentation error if last element of LIST is empty #15962

Closed
p5pRT opened this issue Apr 24, 2017 · 9 comments
Closed

die & warn documentation error if last element of LIST is empty #15962

p5pRT opened this issue Apr 24, 2017 · 9 comments

Comments

@p5pRT
Copy link

p5pRT commented Apr 24, 2017

Migrated from rt.perl.org#131203 (status was 'open')

Searchable as RT131203$

@p5pRT
Copy link
Author

p5pRT commented Apr 24, 2017

From msh210@gmail.com

Hi,

https://perldoc.perl.org/functions/die.html says "If the last element of
LIST does not end in a newline, the current script line number and input
line number (if any) are also printed, and a newline is supplied." It
should instead say "If the string thus to be printed does not end in a
newline, the current script line number and input line number (if any) are
also printed, and a newline is supplied.", since perl -e"die
qq[test$/],undef" does not append file and line information (tested in
Strawberry 5.24.0). (This same error appears in the docs for warn.)

Yours,

Michael Hamm



Flags​:
  category=docs
  severity=low

@p5pRT
Copy link
Author

p5pRT commented May 15, 2017

From @jkeenan

Thank you very much for this report. However, ...

The website perldoc.perl.org is not maintained by Perl 5 Porters. Hence, defective links on pages on that site should be reported to the website's maintainer; search for 'Site maintained by' on any page to learn how to contact that maintainer.

See the two programs attached, which illustrate the documentation about which you voiced concerns. The source code documentation in pod/perlfunc.pod appears to be correct.

--
James E Keenan (jkeenan@​cpan.org)

@p5pRT
Copy link
Author

p5pRT commented May 15, 2017

From @jkeenan

131203-die-nl.pl

@p5pRT
Copy link
Author

p5pRT commented May 15, 2017

From @jkeenan

131203-die.pl

@p5pRT
Copy link
Author

p5pRT commented May 15, 2017

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented May 15, 2017

@jkeenan - Status changed from 'open' to 'rejected'

@p5pRT p5pRT closed this as completed May 15, 2017
@p5pRT
Copy link
Author

p5pRT commented May 18, 2017

From msh210@gmail.com

On Tue, May 16, 2017 at 2​:44 AM, James E Keenan via RT <
perlbug-followup@​perl.org> wrote​:

The website perldoc.perl.org is not maintained by Perl 5 Porters. Hence,
defective links on pages on that site should be reported to the website's
maintainer; search for 'Site maintained by' on any page to learn how to
contact that maintainer.

See the two programs attached, which illustrate the documentation about
which you voiced concerns. The source code documentation in
pod/perlfunc.pod appears to be correct.

The test cases you attached don't seem to be relevant. This is​:

  die ( "test\n" , undef )

This seems to be a problem with the docs and not just their Web version.

Thanks,

--
Michael Hamm

@p5pRT
Copy link
Author

p5pRT commented May 22, 2017

@iabyn - Status changed from 'rejected' to 'open'

@p5pRT
Copy link
Author

p5pRT commented May 22, 2017

From @iabyn

On Wed, May 17, 2017 at 10​:53​:40PM +0300, Michael Hamm wrote​:

On Tue, May 16, 2017 at 2​:44 AM, James E Keenan via RT <
perlbug-followup@​perl.org> wrote​:

The website perldoc.perl.org is not maintained by Perl 5 Porters. Hence,
defective links on pages on that site should be reported to the website's
maintainer; search for 'Site maintained by' on any page to learn how to
contact that maintainer.

See the two programs attached, which illustrate the documentation about
which you voiced concerns. The source code documentation in
pod/perlfunc.pod appears to be correct.

The test cases you attached don't seem to be relevant. This is​:

die \( "test\\n" \, undef \)

This seems to be a problem with the docs and not just their Web version.

I agree that the docs for die are at fault. Similarly

  $ perl -we'die "foo\n"'
  foo
  $ perl -we'die "foo\n", ""'
  foo
  $

I'm marking the ticket as re-opened.

--
A power surge on the Bridge is rapidly and correctly diagnosed as a faulty
capacitor by the highly-trained and competent engineering staff.
  -- Things That Never Happen in "Star Trek" #9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant