code: public NameSpace swap( NameSpace newTop ) {
          NameSpace oldTop = stack.pop();
          stack.push(newTop);
          return oldTop;
      }
docs: Swap in the value as the new top of the stack and return the old
  value.