X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=Magic.xs;h=735683c600e192599122ac3d8785809a5fcb68d4;hb=ace906d7e76ed647adbd1ab1243ac9bdbde9b1d5;hp=fa09ec197eaaf5f4adda03367ff45c0bc47582c8;hpb=de17a4857e738f4474bea721e6064f1b52273f6d;p=perl%2Fmodules%2FVariable-Magic.git diff --git a/Magic.xs b/Magic.xs index fa09ec1..735683c 100644 --- a/Magic.xs +++ b/Magic.xs @@ -1098,8 +1098,16 @@ STATIC int vmg_svt_free(pTHX_ SV *sv, MAGIC *mg) { #endif has_err = SvTRUE(ERRSV); - if (IN_PERL_COMPILETIME && !had_err && has_err) - ++PL_error_count; + if (IN_PERL_COMPILETIME && !had_err && has_err) { + if (PL_errors) + sv_catsv(PL_errors, ERRSV); + else + Perl_warn(aTHX_ "%s", SvPV_nolen(ERRSV)); +#ifdef PL_parser + if (PL_parser) +#endif + ++PL_error_count; + } SPAGAIN; svr = POPs;