Try to unify trait definitions and infer types.

    We still don't properly specialize.