code: public void addChildScope(Scope child) {
          if (childScopes == null) {
              childScopes = new ArrayList<Scope>();
          }
          childScopes.add(child);
          child.setParentScope(this);
      }
docs: Add a scope to our list of child scopes.
  Sets the child's parent scope to this scope.
  @throws IllegalStateException if the child's parent scope is
  non-{@code null}