Flush PL_stashcache on glob-to-glob assignment
authorFather Chrysostomos <sprout@cpan.org>
Sat, 8 Jun 2013 21:38:02 +0000 (14:38 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Sun, 9 Jun 2013 06:25:13 +0000 (23:25 -0700)
commit210fdecd4386556fdb4aa40a112c04b9f37be553
tree3f866f75d64d7ae8cd96c1a8b61f282a72695edc
parent1f3ffe4c6058f20e1f7d746ababdd669651e8d2b
Flush PL_stashcache on glob-to-glob assignment

Commit dc93d7fb33f6b2093 says this:

    Flush PL_stashcache when assigning a file handle to a typeglob.

    File handles take priority over stashes for method dispatch.
    Assigning a file handle to a typeglob potentially creates a file
    handle where one did not exist before.  As PL_stashcache only con-
    tains entries for names which unambiguously resolve to stashes,
    such a change may mean that PL_stashcache now contains an invalid
    entry.  As it’s hard to work out exactly which entries might be
    affected, simply flush the entire cache and let it rebuild itself.

But it only applied to io-to-glob assignment.  This commit extends it
to glob-to-glob assignment.
sv.c
t/op/method.t