Is there a clever way to undef an "active" subroutine? I'd like to do this:
I find it curious that undef-ing is not permitted but that this is allowed:sub foo { undef &foo; ... }
In my case the sub I want to undef is an AUTOLOAD sub, and I'd want to remove it from the symbol table so it can't get called again.sub foo { *{foo} = sub { warn "second foo" }; ... }
In reply to undef-ing an active subroutine by perl5ever
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |