[perl #87064] eval no longer shares filters
authorFather Chrysostomos <sprout@cpan.org>
Tue, 29 Mar 2011 15:33:30 +0000 (08:33 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Sun, 3 Apr 2011 23:20:32 +0000 (16:20 -0700)
commit27fcb6ee0bb7765fc92447e27763fa4ab7ae9baa
treec59544566b46bbc9cd288c8fbbd12cf3b5793d2c
parentc2c97af8cb32b7e57f42c6e11ab8084075742761
[perl #87064] eval no longer shares filters

Before this commit:

commit f07ec6dd59215a56bc1159449a9631be7a02a94d
Author: Zefram <zefram@fysh.org>
Date:   Wed Oct 13 19:05:19 2010 +0100

    remove filter inheritance option from lex_start

    The only uses of lex_start that had the new_filter parameter false,
    to make the new lexer context share source filters with the previous
    lexer context, were uses with rsfp null, which therefore never invoked
    source filters.  Inheriting source filters from a logically unrelated
    file seems like a silly idea anyway.

string evals could inherit the same source filter space as the cur-
rently compiling code. Despite what the quoted commit message says,
sharing source filters allows filters to be inherited in both direc-
tions: A source filter created when the eval is being compiled also
applies to the file with which it is sharing its space.

There are at least 20 CPAN distributions relying on this behaviour
(or, rather, what could be considered a Test::More bug). So this com-
mit restores the source-filter-sharing capability. It does not change
the current API or make public the API for sharing source filters, as
this is supposed to be a temporary stop-gap measure for 5.14.
MANIFEST
ext/XS-APItest/APItest.pm
ext/XS-APItest/APItest.xs
ext/XS-APItest/t/eval-filter.t [new file with mode: 0644]
op.c
parser.h
pp_ctl.c
toke.c