Subject: | Different behavior of CORE::bless and the overwritten version |
Your overwritten bless method behaves a little different like te
original one. It seems to be that CORE::bless has a prototype like
(@;$)
because if you say
bless(({},2,3,4), __PACKAGE__);
it croaks with: "can't bless non reference...". If you say
bless({},2,3,__PACKAGE)
it croaks with "Too many arguments...". I dont have any suggestion to
solve this, because if you add the (@;$) prototype to the new bless
method, it doesn't behave in the same way.