Version française
Home     About     Download     Resources     Contact us    
Browse thread
recursive records with weak hashtbl
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Florent Ouchet <florent.ouchet@i...>
Subject: Re: [Caml-list] recursive records with weak hashtbl
Vsevolod Fedorov a e'crit :
<snip>
> Is it possible at all?
>   
Yes, you have to use "type .. and .. ;;" statements

for instance:
type a =
{
id : int ;
mutable field_1 : string;
mutable field_b : b;
}
and b =
{
id : int;
mutable field_2 : string;
field_a_list : a array; (* they referenced me *)
};;
> Is it possible with A and B declarations in separate files?
>   
I don't think so.

- Florent