Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Phantom types: transparency vs rogue unification
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2008-06-25 (15:02)
From: Jacques Carette <carette@m...>
Subject: Re: [Caml-list] Phantom types: transparency vs rogue unification
How about leaving your type opaque but changing your implementation of 
parse to
        let parse s = Stringies.make (float_of_string s)
In my tests, this works as you intended.

Note that I would personally implement Stringies_IO a Functor over 
Stringies rather than having explicit dependencies.