Compiles again after a good thrashing, but probably broken