[erlang-questions] Type definition
Cláudio Amaral
coa@REDACTED
Mon Aug 3 20:46:52 CEST 2009
Cláudio Amaral escreveu:
> Can one define polymorphic type definitions?
>
> For example:
>
> poly_tree I::integer B::type
> empty
> | {branch, [B], poly_tree(I,B),poly_tree(I,B)}
>
> where [B] is a list with I elements
>
>
> Regards,
> Cláudio
>
>
> ________________________________________________________________
> erlang-questions mailing list. See http://www.erlang.org/faq.html
> erlang-questions (at) erlang.org
>
Forgot to mention that B is a type and then [B] will have elements of type B
More information about the erlang-questions
mailing list