brian ripley's fix of the profile.merMod bug that arises with lazy_duplicate_ok