-
Notifications
You must be signed in to change notification settings - Fork 540
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PATCH] -mpragma (eg strict) fail silent blindsiding #15998
Comments
From ronaldxs@software-path.comCreated by ronaldxs@software-path.comdocument -mpragma (eg strict) fail silent "perl -Mstrict" is used all the time and I noticed that "perl -mstrict" A programmer using Perl should not need to know how to write a custom Perl Info
|
From ronaldxs@software-path.com0001-perlrun-warn-on-mpragma-eg-strict-blindsiding.patchFrom b85ff045c4480eca8989420062c698a819c47105 Mon Sep 17 00:00:00 2001
From: Ronald Schmidt <ronaldxs@software-path.com>
Date: Mon, 29 May 2017 14:41:49 -0400
Subject: [PATCH] perlrun: warn on -mpragma (eg strict) blindsiding
A programmer using Perl should not need to know how to write a custom
pragma to understand that -mstrict does not work because of the empty
import list.
---
pod/perlrun.pod | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/pod/perlrun.pod b/pod/perlrun.pod
index dff9f71..5edeb35 100644
--- a/pod/perlrun.pod
+++ b/pod/perlrun.pod
@@ -685,6 +685,11 @@ A consequence of this is that B<-MI<MODULE>=number> never does a version check,
unless C<I<MODULE>::import()> itself is set up to do a version check, which
could happen for example if I<MODULE> inherits from L<Exporter>.
+Lowercase B<-m> should not be expected to work for a pragma (eg C<strict>)
+since the empty import list - C<()> - prevents the call to import usually used
+by a pragma set active and other status for the current scope. See
+L<perlpragma>.
+
=item B<-n>
X<-n>
--
1.9.1
|
From @jkeenanOn Tue, 06 Jun 2017 14:44:56 GMT, ronaldxs wrote:
I think your argument is correct and the patch should be applied. However, I think something is amiss in the syntax of this part: ##### Something about "set active and other status" doesn't sound right. Can you clarify? Thank you very much. -- |
The RT System itself - Status changed from 'new' to 'open' |
From zefram@fysh.orgFixed with a different documentation edit in commit -zefram |
@xsawyerx - Status changed from 'open' to 'pending release' |
From @khwilliamsonThank you for filing this report. You have helped make Perl better. With the release yesterday of Perl 5.28.0, this and 185 other issues have been Perl 5.28.0 may be downloaded via: If you find that the problem persists, feel free to reopen this ticket. |
@khwilliamson - Status changed from 'pending release' to 'resolved' |
Migrated from rt.perl.org#131518 (status was 'resolved')
Searchable as RT131518$
The text was updated successfully, but these errors were encountered: