This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Don't refer to specific line numbers in test code regex
[perl5.git] / lib / shellwords.pl
index 1c2c894..b562f5f 100644 (file)
@@ -1,3 +1,5 @@
+warn "Legacy library @{[(caller(0))[6]]} will be removed from the Perl core distribution in the next major release. Please install it from the CPAN distribution Perl4::CoreLibs. It is being used at @{[(caller)[1]]}, line @{[(caller)[2]]}.\n";
+
 ;# This legacy library is deprecated and will be removed in a future
 ;# release of perl.
 ;#
 ;#     or
 ;#     @words = shellwords();          # defaults to $_ (and clobbers it)
 
-warn( "The 'shellwords.pl' legacy library is deprecated and will be"
-      . " removed in the next major release of perl. Please use the"
-      . " Text::ParseWords module instead." );
-
 require Text::ParseWords;
 *shellwords = \&Text::ParseWords::old_shellwords;