// reconstruct using a node builder, which seems to be required for
// type nodes.
NodeBuilder nb(ret.getKind());
- if (ret.getMetaKind() == kind::metakind::PARAMETERIZED)
- {
- // push the operator
- nb << NodeManager::operatorFromType(ret);
- }
+ // there are no parameterized types
+ Assert (ret.getMetaKind() != kind::metakind::PARAMETERIZED);
for (TypeNode::const_iterator j = ret.begin(), iend = ret.end();
j != iend;
++j)
TypeNode NodeManager::mkSort()
{
NodeBuilder nb(this, kind::SORT_TYPE);
- Node sortTag = NodeBuilder(this, kind::SORT_TAG);
- nb << sortTag;
return nb.constructTypeNode();
}
TypeNode NodeManager::mkSort(const std::string& name)
{
NodeBuilder nb(this, kind::SORT_TYPE);
- Node sortTag = NodeBuilder(this, kind::SORT_TAG);
- nb << sortTag;
TypeNode tn = nb.constructTypeNode();
setAttribute(tn, expr::VarNameAttr(), name);
return tn;
{
Assert(arity > 0);
NodeBuilder nb(this, kind::SORT_TYPE);
- Node sortTag = NodeBuilder(this, kind::SORT_TAG);
- nb << sortTag;
TypeNode type = nb.constructTypeNode();
setAttribute(type, expr::VarNameAttr(), name);
setAttribute(type, expr::SortArityAttr(), arity);
*/
static bool isNAryKind(Kind k);
- /**
- * Returns a node representing the operator of this `TypeNode`.
- * PARAMETERIZED-metakinded types (the SORT_TYPE is one of these) have an
- * operator. "Little-p parameterized" types (like Array), are OPERATORs, not
- * PARAMETERIZEDs.
- */
- static Node operatorFromType(const TypeNode& tn)
- {
- Assert(tn.getMetaKind() == kind::metakind::PARAMETERIZED);
- return Node(tn.d_nv->getOperator());
- }
-
/** The node manager in the current public-facing cvc5 library context */
static NodeManager* currentNM();
not-well-founded \
"the type for built-in operators"
-variable SORT_TAG "sort tag"
-parameterized SORT_TYPE SORT_TAG 0 "specifies types of user-declared 'uninterpreted' sorts"
+variable SORT_TYPE "specifies types of user-declared 'uninterpreted' sorts"
# The cardinality of uninterpreted sorts is defined infinite here, although they are given special treatment in TypeNode::getCardinalityClass
cardinality SORT_TYPE "Cardinality(Cardinality::INTEGERS)"
well-founded SORT_TYPE \