adding name for redefine when there is an anonymous definition, rewriting global to match dep name