Repair some generics warnings. Reformat to a consistent shorter style.