big rewrite - more to do