[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Axiom-developer] Re: SPAD and Aldor again

From: Martin Rubey
Subject: Re: [Axiom-developer] Re: SPAD and Aldor again
Date: 17 Nov 2006 18:13:03 +0100
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.4

Gabriel Dos Reis <address@hidden> writes:

> | What are "algebraic types"?
> Ralf and you have been doing it in your project, I think.  Basically,
> an algebraic type is any data type on can construct with sum and
> products.  Examples,
>     BinaryTree t = Nil | Node t (BinaryTree t) (BinaryTree t)
> Data of algebraic type are constructed with the constructors, and they
> are deconstructed through pattern matching. 

Well, in fact I need more than that, namely mutually dependent recursively
defined types. I.e., I want to be able to say

A: SomeCat; B: SomeCat;
A == f(A,B) add;
B == g(A,B) add;

as currently possible in Aldor, or, even

l := [SomeDomain, SomeDomain];
l.1 := f(l) add;
l.2 := g(l) add;

(the latter is currently not allowed in Aldor, but it happens to work...)

But I guess, you know that.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]