caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: David Brown <caml-list@davidb.org>
To: Julien Signoles <Julien.Signoles@lri.fr>
Cc: ohl@physik.uni-wuerzburg.de, caml-list@inria.fr
Subject: Re: [Caml-list] Re: Legality of using module types from .mli in .ml
Date: Wed, 15 Jan 2003 13:57:36 -0800	[thread overview]
Message-ID: <20030115215736.GA12377@opus.davidb.org> (raw)
In-Reply-To: <3E259C5D.25AFBC88@lri.fr>

On Wed, Jan 15, 2003 at 06:37:33PM +0100, Julien Signoles wrote:
> >     ohl@wptx47:~misc$ ocamldefun -v
> >     1.02
> >     ohl@wptx47:~misc$ cat a.mli
> >     module type T = sig val n : int end
> >     module M : T
> >     ohl@wptx47:~misc$ cat a.ml
> >     module type T = A.T
> >     module M : T = struct let n = 42 end
> >     ohl@wptx47:~misc$ ocamldefun -d defun a.mli a.ml
> >     ohl@wptx47:~misc$ cd defun/
> >     ohl@wptx47:~defun$ ls
> >     a.cmd  a.ml
> >     ohl@wptx47:~defun$ cat a.ml
> >     module type T = A.T
> >     module M = struct let n = 42 end
> >     ohl@wptx47:~defun$ ocamlopt a.ml
> >     File "a.ml", line 1, characters 16-19:
> >     Unbound module type A.T
> > 
> > I could ignore appendix B of the manual and create a a.cmi:
> > 
> >     ohl@wptx47:~defun$ cp ../a.mli .
> >     ohl@wptx47:~defun$ ocamlc a.mli
> >     ohl@wptx47:~defun$ ocamlopt a.ml

Would it no work to

  ~misc$ ocamlc -c a.mli
  ~misc$ cd defun/
  ~misc$ ocamlopt -c -I .. a.ml

Dave Brown
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners


      reply	other threads:[~2003-01-15 21:58 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-01-14 19:14 [Caml-list] " Thorsten Ohl
2003-01-15 16:28 ` [Caml-list] " Julien Signoles
2003-01-15 16:59   ` Thorsten Ohl
2003-01-15 17:37     ` Julien Signoles
2003-01-15 21:57       ` David Brown [this message]

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=20030115215736.GA12377@opus.davidb.org \
    --to=caml-list@davidb.org \
    --cc=Julien.Signoles@lri.fr \
    --cc=caml-list@inria.fr \
    --cc=ohl@physik.uni-wuerzburg.de \
    /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).