I know that Cons/2 and Nil terms have a special meaning, but what about other Cons terms?

Module:
—————————————————-
module foo
imports list-cons
signature
constructors
Cons : Term
Appl : Term * List(Term) -> Term

strategies

main = Implode

rules
Implode : Appl(Cons(), [c, cs]) -> [c | cs]
—————————————————-

Compile:
—————————————————-
> strc -i foo.str
compiling foo.str
front-end succeeded: user 0.24 system 0.12
optimization succeeded: user 0.08 system 0.14
No pp entry found for: [“Match”]
** ERROR: cannot rewrite to box: Match(Op(“Cons”,[]),Id(“d_0”))
/pkg/strategoxt/2004-03-20-14-35/bin/ast2abox: rewriting failed
compilation failed (0.74 secs)
—————————————————-

Submitted on 21 March 2004 at 10:50

On 25 November 2004 at 14:39 Jira commented:

STR-25, martin:
The other Cons issue is more clear.

Log in to post comments