Updates the def function to look up previous definitions of globals when a rigid name is specified.