rewrite step definition