If you set or export an environment variable in bash, you can unset it. If you set an alias in bash, you can unalias it. But there doesn't seem to be an unfunction.
Consider this (trivial) bash function, for example, set in a .bash_aliases file and read at shell initialization.
function foo () { echo "bar" ; }
How can I clear this function definition from my current shell?
(Changing the initialization files or restarting the shell doesn't count.)
unfunctionwould be a nice name for a command :-) – Joey Jun 19 '10 at 18:00