Correctly replace bindings with the most recently bound re