public boolean equalsWithComments(Object o) {

    /* generated by template ast.ErrorIfNull*/
    Log.errorIfNull(o, "0xA7006_897 Parameter 'o' must not be null.");

    /* generated by template ast.additionalmethods.EqualsWithComments*/

    ASTNoptrnewdeclarator comp;
    if ((o instanceof ASTNoptrnewdeclarator)) {
      comp = (ASTNoptrnewdeclarator) o;
    } else {
      return false;
    }
    if (!equalAttributes(comp)) {
      return false;
    }
    // comparing comments
    if (get_PreComments().size() == comp.get_PreComments().size()) {
      java.util.Iterator<de.monticore.ast.Comment> one = get_PreComments().iterator();
      java.util.Iterator<de.monticore.ast.Comment> two = comp.get_PreComments().iterator();
      while (one.hasNext()) {
        if (!one.next().equals(two.next())) {
          return false;
        }
      }
    } else {
      return false;
    }

    if (get_PostComments().size() == comp.get_PostComments().size()) {
      java.util.Iterator<de.monticore.ast.Comment> one = get_PostComments().iterator();
      java.util.Iterator<de.monticore.ast.Comment> two = comp.get_PostComments().iterator();
      while (one.hasNext()) {
        if (!one.next().equals(two.next())) {
          return false;
        }
      }
    } else {
      return false;
    }
    return true;
  }
  public ASTNoptrnewdeclarator deepClone(ASTNoptrnewdeclarator result) {

    /* generated by template ast.ErrorIfNull*/
    Log.errorIfNull(result, "0xA7006_236 Parameter 'result' must not be null.");

    /* generated by template ast.additionalmethods.DeepCloneWithParameters*/

    super.deepClone(result);

    result.expression =
        this.expression.isPresent()
            ? Optional.ofNullable((cpp14._ast.ASTExpression) this.expression.get().deepClone())
            : Optional.empty();
    result.noptrnewdeclarator =
        this.noptrnewdeclarator.isPresent()
            ? Optional.ofNullable(
                (cpp14._ast.ASTNoptrnewdeclarator) this.noptrnewdeclarator.get().deepClone())
            : Optional.empty();
    result.leftBracketL =
        this.leftBracketL.isPresent()
            ? Optional.ofNullable((String) this.leftBracketL.get())
            : Optional.empty();
    result.constantexpression =
        this.constantexpression.isPresent()
            ? Optional.ofNullable(
                (cpp14._ast.ASTConstantexpression) this.constantexpression.get().deepClone())
            : Optional.empty();
    result.rightBracketL =
        this.rightBracketL.isPresent()
            ? Optional.ofNullable((String) this.rightBracketL.get())
            : Optional.empty();
    result.attributespecifierseq =
        this.attributespecifierseq.isPresent()
            ? Optional.ofNullable(
                (cpp14._ast.ASTAttributespecifierseq) this.attributespecifierseq.get().deepClone())
            : Optional.empty();
    result.symbol =
        this.symbol.isPresent()
            ? Optional.ofNullable((Symbol) this.symbol.get())
            : Optional.empty();
    result.enclosingScope =
        this.enclosingScope.isPresent()
            ? Optional.ofNullable((Scope) this.enclosingScope.get())
            : Optional.empty();
    return result;
  }