http://qs1969.pair.com?node_id=573935


in reply to adding temporary method to a class

{ local *Class::method = sub { ... }; ... }

For anything in "...", called by "..." directly, or called by "..." indirectly, the method will exist.

I'm not sure doing so is a good idea, however. Why do you want to do this?