diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2009-07-07 11:04:13 +0200 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2009-07-07 11:07:26 +0200 |
commit | 5cc917d61a1b0b6683ece694d00cdb1abdf9c0d9 (patch) | |
tree | 9b476455d5e217c2f5decfd2c75417546656ae50 /pp_ctl.c | |
parent | 53eb19dd57d98e5a28ec6e1a56a1a40ce469145f (diff) | |
download | perl-5cc917d61a1b0b6683ece694d00cdb1abdf9c0d9.tar.gz |
Fast enabling of strictures when version 5.11.0 is required
We don't load strict.pm, we just manipulate the hint bits.
Plus more tests.
Diffstat (limited to 'pp_ctl.c')
-rw-r--r-- | pp_ctl.c | 5 |
1 files changed, 1 insertions, 4 deletions
@@ -3258,12 +3258,9 @@ PP(pp_require) /* If a version >= 5.11.0 is requested, strictures are on by default! */ if (PL_compcv && vcmp(sv, sv_2mortal(upg_version(newSVnv(5.011000), FALSE))) >= 0) { - ENTER; - Perl_load_module(aTHX_ 0, newSVpvs("strict"), NULL, NULL, NULL); - LEAVE; + PL_hints |= (HINT_STRICT_REFS | HINT_STRICT_SUBS | HINT_STRICT_VARS); } - RETPUSHYES; } name = SvPV_const(sv, len); |