caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Guillaume Yziquel <guillaume.yziquel@citycable.ch>
To: blue storm <bluestorm.dylc@gmail.com>
Cc: Alexey Rodriguez <mrchebas@gmail.com>, OCaml List <caml-list@inria.fr>
Subject: Re: [Caml-list] Partially hiding modules in packages
Date: Sat, 28 Nov 2009 19:49:43 +0100	[thread overview]
Message-ID: <4B1170C7.1070004@citycable.ch> (raw)
In-Reply-To: <527cf6bc0909091240u3aa0bb40u3186457a33c0636c@mail.gmail.com>

blue storm a écrit :
> 
> Regarding your original problem, I've had the same needs and came up
> with a slightly different solution : in order to avoid the additional
> indirection level related to -pack (Foobar.Foo), is used a flattened
> representation by adding a "foobar.ml" file containing only :
> 
>   include Foo
> 
> (and possibly include of other modules in the package). Then the
> foobarl.mli is :
> 
>   type foo_t
> 
>   val initial : foo_t
>   val show : foo_t -> string
> 
> And values can be referred with Foobar.foo, instead of Foobar.Foo.foo.
> Of course this is only useful if you don't want the user to see the
> internal module hierarchy, wich may not be what you had in mind.

Where do you put the foobar.ml? I've been trying it all over, I do not 
see how you can flatten something that you pack.

Do you put foobar.ml at the same level of your directory foobar/, or in 
you directory foobar/ ?

Or am I understanding you wrong?

All the best,

-- 
      Guillaume Yziquel
http://yziquel.homelinux.org/


  parent reply	other threads:[~2009-11-28 18:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-09 19:00 Alexey Rodriguez
2009-09-09 19:40 ` [Caml-list] " blue storm
2009-09-10 12:29   ` Alexey Rodriguez
2009-11-28 18:49   ` Guillaume Yziquel [this message]
2009-09-09 20:24 ` Alain Frisch
2009-09-10  6:08 ` Jean-Christophe Filliâtre

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B1170C7.1070004@citycable.ch \
    --to=guillaume.yziquel@citycable.ch \
    --cc=bluestorm.dylc@gmail.com \
    --cc=caml-list@inria.fr \
    --cc=mrchebas@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).