Synopsis A type in a declaration is not wellformed.
Description Types should respect some structural rules and this error signals a violation of these rules. Examples of violations are:
  • a non-parametric type has parameters.
  • a parametric type has an incorrect number of parameters.
Remedy: correct the type.
rascal>bool[int] x;
|stdin:///|(0,4,<1,0>,<1,4>): Non-well-formed type: bool cannot have type arguments.
rascal>list[int,str] l;
|stdin:///|(0,4,<1,0>,<1,4>): Non-well-formed type: list should have exactly one type argument, like list[value]
rascal>map[str, int, int]  m;
|stdin:///|(0,3,<1,0>,<1,3>): Non-well-formed type: map should have exactly two type arguments, like map[value,value]
rascal>set[int,str] s;
|stdin:///|(0,3,<1,0>,<1,3>): Non-well-formed type: set should have exactly one type argument, like set[value]
Is this page unclear, or have you spotted an error? Please add a comment below and help us to improve it. For all other questions and remarks, visit