WIP New validator

This still needs some comments and tests but the basic structure is there. Tear it up.
Those are just for debugging. I might just yank them out entirely.