complete rewriting.