Rewrite `clock`