code: @Nonnull
    public ExpressionTreeElement getRoot() {
      if (last.isEmptySlot()) {
        return this.last;
      } else {
        ExpressionTreeElement element = last;
        while (!Thread.currentThread().isInterrupted()) {
          final ExpressionTreeElement next = element.getParent();
          if (next == null) {
            return element;
          } else {
            element = next;
          }
        }
      }
      return ExpressionTreeElement.EMPTY_SLOT;
    }
docs: Get the root of the tree
  
  @return the root of the tree or EMPTY_SLOT if the tree is empty