Language: refactor with typeclass

This makes it conceptually simpler because now we just have a single
instance of the LangDesc typeclass instead of multiple separate,
independent functions for the same task.