in reply to Re^2: Challenge: sort weekdays in week-order (Time::Piece)
in thread Challenge: sort weekdays in week-order (elegantly and efficiently)

Hmm... Not present in 5.26.1, works but not documented in 5.37.1. I'm not sure I'd use it.

map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]

Replies are listed 'Best First'.
Re^4: Challenge: sort weekdays in week-order (Time::Piece)
by LanX (Saint) on Jul 22, 2022 at 13:00 UTC
    oh I see _get_localization is new in Time::Piece

    I just needed it anyway only to access the private

    my @FULLDAY_LIST = qw(Sunday Monday Tuesday Wednesday Thursday Friday Saturday);

    There are some (ugly) hacks to get it directly tho ...

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery