refactored some more
Larger refactorization of Solver.hs, starting to look OK, though.