More cleanup. Constant renames and generics tweaks