summaryrefslogtreecommitdiff
path: root/pp_ctl.c
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2010-11-25 17:08:18 +0000
committerNicholas Clark <nick@ccl4.org>2010-11-25 17:10:56 +0000
commit88e9444c4ef58850472b05bba333f4072222d0da (patch)
treed9b48abc5e3966428d539fe5780b71ab3382ef8c /pp_ctl.c
parentb19934fbc3c981a7e4bb888f0d6a20f926a0bc17 (diff)
downloadperl-88e9444c4ef58850472b05bba333f4072222d0da.tar.gz
Make BEGIN {require 5.12.0} behave as documented.
Previously in a BEGIN block, require was behaving identically to use 5.12.0 - ie erroneously executing the use feature ':5.12.0'; and use strict; use warnings behaviour, which only use was documented to provide.
Diffstat (limited to 'pp_ctl.c')
-rw-r--r--pp_ctl.c17
1 files changed, 0 insertions, 17 deletions
diff --git a/pp_ctl.c b/pp_ctl.c
index 54e7c256a7..3629c93c1f 100644
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -3465,23 +3465,6 @@ PP(pp_require)
}
}
- /* We do this only with "use", not "require" or "no". */
- if (PL_compcv && !(cUNOP->op_first->op_private & OPpCONST_NOVER)) {
- /* If we request a version >= 5.9.5, load feature.pm with the
- * feature bundle that corresponds to the required version. */
- if (vcmp(sv, sv_2mortal(upg_version(newSVnv(5.009005), FALSE))) >= 0) {
- SV *const importsv = vnormal(sv);
- *SvPVX_mutable(importsv) = ':';
- ENTER_with_name("load_feature");
- Perl_load_module(aTHX_ 0, newSVpvs("feature"), NULL, importsv, NULL);
- LEAVE_with_name("load_feature");
- }
- /* If a version >= 5.11.0 is requested, strictures are on by default! */
- if (vcmp(sv, sv_2mortal(upg_version(newSVnv(5.011000), FALSE))) >= 0) {
- PL_hints |= (HINT_STRICT_REFS | HINT_STRICT_SUBS | HINT_STRICT_VARS);
- }
- }
-
RETPUSHYES;
}
name = SvPV_const(sv, len);