in reply to Re: Localized weekday names
in thread Localized weekday names

I suspect I have some different version of Time::Piece than what you have:
mcp:~>perl days.pl Can't locate object method "use_locale" via package "Time::Piece" at d +ays.pl line 10.
and if I remove the "use_locale" line, I get this interesting result:
Days are Sun Mon Tue Wed Thu Fri Sat Days are Time::Piece
I must admit, I have no clue why the second call to Time::Piece does not work anymore.

Versions are:

p5-Time-Piece-1.23_1 Time::Piece - Object Oriented time obje +cts This is perl 5, version 24, subversion 3 (v5.24.3) built for amd64-fre +ebsd-thread-multi
Last, but not least, Time::Piece apparently does not care for the locale by default:
mcp:~>LC_TIME=de_DE.UTF-8 perl -MTime::Piece -le 'print join",",Time:: +Piece->day_list' Sun,Mon,Tue,Wed,Thu,Fri,Sat

Replies are listed 'Best First'.
Re^3: Localized weekday names
by hippo (Archbishop) on Nov 03, 2017 at 16:04 UTC
    p5-Time-Piece-1.23_1

    Time::Piece 1.23 is over 4 years old. That really doesn't count as "recent" so no, you would need to upgrade it to take advantage of the new features (and bug fixes and stability improvements and ...). My script was tested against version 1.31_04 which is more modern and the current version is 1.3202 from about 6 weeks ago.

    Last, but not least, Time::Piece apparently does not care for the locale by default

    This is precisely why the newer versions have use_locale :-)