in reply to Perl named operators and builtin subs introduced since 5.6
in thread Finding when a feature or keyword was introduced

Great table, thanks! Is there any way to find out when features other than keywords were added? I'm currently trying to find (1) when ref() began returning 'Regexp' and (2) when class 'Regexp' was added, if that was more recent than (1). Both ref() and Scalar::Util::blessed() return 'Regexp' as of v5.20.2. The referenced 5.38 delta page contains a link to select earlier versions, but it doesn't seem to work; a "raptor not found" error is displayed.

  • Comment on Re: Perl named operators and builtin subs introduced since 5.6

Replies are listed 'Best First'.
Re^2: Perl named operators and builtin subs introduced since 5.6
by choroba (Cardinal) on Apr 16, 2025 at 08:49 UTC
    I collect some non-features in Syntax::Construct, but Regexp is not one of them (I might add it, though).

    map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]
Re^2: Perl named operators and builtin subs introduced since 5.6
by hippo (Archbishop) on Apr 16, 2025 at 08:19 UTC

    A quick perusal through the docs for ref for historical versions of Perl suggests that the Regexp class started being reported in 5.8.9 but this is not mentioned in the 5.8.9 delta AFAICS. Nowadays that really ought to be so long ago that it doesn't matter anyway.


    🦛

Re^2: Perl named operators and builtin subs introduced since 5.6
by ikegami (Patriarch) on Apr 16, 2025 at 17:23 UTC

    It's been that way since at least 5.8.9. ("t" means threaded. Ignore that.)

    $ for v in 5.8.9 5.10t 5.12t 5.14t 5.16t 5.18t 5.20t; do echo $v $v/bin/perl -le'print ref( qr/x/ )' done 5.8.9 Regexp 5.10t Regexp 5.12t Regexp 5.14t Regexp 5.16t Regexp 5.18t Regexp 5.20t Regexp