English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
ocamlgraph ConcreteBidirectional and Dot
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2009-04-07 (07:27)
From: Jean-Christophe_Filliâtre <Jean-Christophe.Filliatre@l...>
Subject: Re: [Caml-list] ocamlgraph ConcreteBidirectional and Dot

Sorry for the late answer...

> I've a small problem with ocamlgraph.
> I want to parse a dot graph into a ConcreteBidirectional.
> The problem is that the signature needed for Dot.Parse requires a function
> edge, but I've no mean to specify a label (since it is unlabelled !!)... 
> The functor for ConcreteBidirectional says E.t = (V.t * V.t), 
> but I don't quite understand the type of B.G.E.label ... 

You're right, some type information is missing and there is no way to
instantiate the Dot functor with the current signature of

One easy patch (if you are compiling ocamlgraph from sources) is to add
the constraint

	... and type E.label = unit

to the signature of functor ConcreteBidirectional. I think we'll do that
in the next release of ocamlgraph (and similarly for other unlabeled
graph data structures provided in ocamlgraph).

Hope this helps,