big rewrite, part 2 of ???