Removing dead code in Rewrite.