Added rewrite_changes().

Signed-off-by: Kouhei Maeda <mkouhei@palmtb.net>