X-Git-Url: https://perl5.git.perl.org/perl5.git/blobdiff_plain/dd9a6ccfcb1b5e26680c14c1663ea9fac4480690..79a3e5ea36208f2f54e36fa3a73c72808a6d0ad8:/t/lib/croak/pp_hot?ds=sidebyside diff --git a/t/lib/croak/pp_hot b/t/lib/croak/pp_hot index 1e12fbb..0b65d7c 100644 --- a/t/lib/croak/pp_hot +++ b/t/lib/croak/pp_hot @@ -11,3 +11,16 @@ Undefined subroutine &main::foo called at - line 3. &$foosub; EXPECT Undefined subroutine &main::foo called at - line 2. +######## +# NAME calling undef scalar + &{+undef}; +EXPECT +Can't use an undefined value as a subroutine reference at - line 1. +######## +# NAME calling undef magical scalar + sub TIESCALAR {bless[]} + sub FETCH {} + tie $tied, ""; + &$tied; +EXPECT +Can't use an undefined value as a subroutine reference at - line 4.