various code cleanup tasks and formatting; some experimenting with polymorphic inference approaches