
Two theories as to why some sea slugs do this is to rid themselves of parasitic crustaceans or to avoid getting totally eaten by a predator. This would be similar to talent of the sea cucumber who can expel it's innards in the face of a predator, and regrow them. If humans could do this there might be some troublesome messes around town, but also might be quite effective to deter muggers!
Whoa! Weird! (How's that for a thoughtful and scientific comment?)