in reply to Re^5: Making each(@ary) work on 5.10?
in thread Making each(@ary) work on 5.10?

I have included the previous version of Tie::ArrayAsHash in feature::each_on_array (soon to be renamed to Syntax::Feature::*, as per mst's suggestion). If you decide to upload this to CPAN, I'll remove the inclusion and depend on that instead.

Replies are listed 'Best First'.
Re^7: Making each(@ary) work on 5.10?
by tobyink (Canon) on Jul 28, 2012 at 09:48 UTC

    tobyink finally twigs that sedusedan==SHARYANTO.

    I don't plan on uploading it. Probably better to bundle the module rather than inline it. Especially as you seem to be inlining it three times.

    Be aware that Syntax::Feature:: modules use a different mechanism for installing methods to their caller. They don't use import but instead use a method called install. My own Syntax::Feature::Maybe is a fairly simple demonstration.

    Be aware that the original version of Tie::ArrayAsHash has a bug in EXISTS. The second version fixes that. Also, the second version uses CORE::each internally within aeach mostly just to clarify what's going on, but also just in case some bizarro situation ends up making it recursively call itself when installed as CORE::GLOBAL::each.

    perl -E'sub Monkey::do{say$_,for@_,do{($monkey=[caller(0)]->[3])=~s{::}{ }and$monkey}}"Monkey say"->Monkey::do'