irritability of structure name conflicts

From: Dave Mason (dmason@sarg.Ryerson.CA)
Date: Tue Jul 13 1999 - 19:59:44 MET DST


Message-Id: <199907131759.NAA00710@sarg.Ryerson.CA>
To: caml-list@inria.fr
Subject: irritability of structure name conflicts
Date: Tue, 13 Jul 1999 13:59:44 -0400
From: Dave Mason <dmason@sarg.Ryerson.CA>

I have the following as part of a type declaration:
        and variable = {name:scheme; mutable value:scheme; next:variable}
        and field = {fname:scheme;
                     fclass:scheme;
                     finit:scheme option;
                     fnext:field}
        and clause = {tags:scheme list;code:scheme list}
        and binding = {id:int;mutable set:bool;value:scheme}

all of which compiles fine, but I get the error:
        The label value belongs to the type Types.binding
        but is here mixed with labels of type Types.variable
at a line that says, in part:
         {name=sym;value=r;next=symbol_table.(idx)}

I didn't get the error before I added the field type! I'm (a)
confused, and (b) irritated that I have to keep making up names for
labels!

Is there some way I can force it to interpret the type constructor as
a particular type so that it chooses the labels from the correct set?

Thanks ../Dave



This archive was generated by hypermail 2b29 : Sun Jan 02 2000 - 11:58:23 MET