refactoring src/Classes.hs