Make my erlang mode hook a global function.