From: Vincent Pit Date: Fri, 4 Jan 2013 12:26:18 +0000 (+0100) Subject: context_info() should ignore %warnings::Bits until perl 5.8.7 X-Git-Tag: v0.22~3 X-Git-Url: http://git.vpit.fr/?a=commitdiff_plain;h=0d4ca8dc9e961839f860c16529bda09010803ad0;p=perl%2Fmodules%2FScope-Upper.git context_info() should ignore %warnings::Bits until perl 5.8.7 Just like what caller() does. --- diff --git a/Upper.xs b/Upper.xs index 7d75d5f..46dc593 100644 --- a/Upper.xs +++ b/Upper.xs @@ -2680,12 +2680,14 @@ context_info_warnings_off: } else if (old_warnings == pWARN_ALL) { HV *bits; context_info_warnings_on: +#if SU_HAS_PERL(5, 8, 7) bits = get_hv("warnings::Bits", 0); if (bits) { SV **bits_all = hv_fetchs(bits, "all", FALSE); if (bits_all) mask = sv_mortalcopy(*bits_all); } +#endif if (!mask) mask = su_newmortal_pvn(WARN_ALLstring, WARNsize); } else {