Beginning of a rewrite.