Some fixes to the renamer