Right now, when installing one module, the function modulename_install() is automatically executed if present, allowing custom post-installation code to be executed.
But the opposite (executing custom uninstall code ins't possible). And I really thing it's interesting to have such functionality.
I've attached one patch here that implements the functionality. I've tested it and seems 100% safe (its completely paired with the install one). So I would introduce it for 1.9.