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

stat() in array context does not work with perl 5.23.3 and greater #291

Open
eserte opened this issue Nov 1, 2015 · 5 comments
Open

stat() in array context does not work with perl 5.23.3 and greater #291

eserte opened this issue Nov 1, 2015 · 5 comments
Labels

Comments

@eserte
Copy link
Contributor

eserte commented Nov 1, 2015

The File-stat.t test fails:

$ perl5.23.4 -Mblib t/File-stat.t                                          
ok 1 - An object of class 'File::stat' isa 'File::stat'
ok 2
not ok 3 - stat() in array context
#   Failed test 'stat() in array context'
#   at t/File-stat.t line 10.
#     Structures begin differing at:
#          $got->[0] = Does not exist
#     $expected->[0] = '17'
not ok 4 - lstat() in array context
#   Failed test 'lstat() in array context'
#   at t/File-stat.t line 11.
#     Structures begin differing at:
#          $got->[0] = Does not exist
#     $expected->[0] = '17'
1..4
# Looks like you failed 2 tests of 4.
@andk
Copy link

andk commented Nov 3, 2015

Now also reported as BBC to https://rt.perl.org/rt3/Ticket/Display.html?id=126545

@schwern
Copy link
Contributor

schwern commented Jan 11, 2016

Need to change stat(@_) to stat($_[0]).

@schwern schwern added the easy label Jan 11, 2016
eserte added a commit to eserte/perl5i that referenced this issue Mar 22, 2016
schwern added a commit that referenced this issue May 31, 2016
fix stat() and lstat() calls for perl 5.23.3+ (#291)
@schwern
Copy link
Contributor

schwern commented May 31, 2016

Fixed by #293

@schwern schwern closed this as completed May 31, 2016
@pghmcfc
Copy link
Contributor

pghmcfc commented Feb 21, 2018

The same fixes should be applied in 0.pm and 1.pm too.

@schwern schwern reopened this Feb 22, 2018
@schwern
Copy link
Contributor

schwern commented Feb 22, 2018

@pghmcfc Well volunteered.

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

No branches or pull requests

4 participants