in reply to Re^5: restore overridden XS methods
in thread restore overridden XS methods
results for 5.6.1 in$\ = "\n"; *t = sub{ print 42 }; *t = \'fred'; *t = [ 1,2,3]; print $]; { local *t = sub { print 'changed' }; print join "\n", t(), $t, "@t"; };
Thus: only the sub is set.Possible unintended interpolation of @t in string at test.pl line 7. Use of uninitialized value in join or string at test.pl line 7. 5.006001 changed 1
Compare that to the result for 5.8.3:
Possible unintended interpolation of @t in string at test.pl line 7. Subroutine main::t redefined at test.pl line 6. 5.008003 changed 1 fred 1 2 3
|
|---|