added check that getRecentName(~) won't return an illegal register name