Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] polymorphic variant question
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Francois Pottier <Francois.Pottier@i...>
Subject: Re: [Caml-list] polymorphic variant question

> I have a number of modules A, B, C that share a single data structure
> between them, all under the control of a central module.  Each wants to
> store different kinds of data in the data structure.

Is it important that the modules share a common data structure? Given that
the data items stored by each module are of a different type, it sounds
like it would be reasonable to have one data structure per module. So,
the central module (which provides the data structure) could be written
as a functor and instantiated once per client module.

-- 
François Pottier
Francois.Pottier@inria.fr
http://pauillac.inria.fr/~fpottier/
-------------------
Bug reports: http://caml.inria.fr/bin/caml-bugs  FAQ: http://caml.inria.fr/FAQ/
To unsubscribe, mail caml-list-request@inria.fr  Archives: http://caml.inria.fr