caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: David MENTRE <dmentre@linux-france.org>
To: Malte Obbel Forsberg <malte@unix.se>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Problem with ocamlmktop
Date: Sat, 11 Sep 2004 18:13:57 +0200	[thread overview]
Message-ID: <87fz5ovl4q.fsf@linux-france.org> (raw)
In-Reply-To: <41422A93.8020606@unix.se> (Malte Obbel Forsberg's message of "Sat, 11 Sep 2004 00:28:35 +0200")

Hello,

Malte Obbel Forsberg <malte@unix.se> writes:

> Now, what I want to do is to use a modified toplevel for mod_ocaml, so I
> won't have to redefine my functions in every ocml (html with ocaml-code
> in it, handled by mod_ocaml) file! I suppose, being quite new to O'Caml,
> I might have missed some other way to achieve this; please enlighten me
> if that is so. :-)

You could use -I option with an absolute path when calling your home
made ocaml.

> What I want to know, then, is if there is some way to define functions
> in an external file and then use the functions in an other interpreted
> file, with "open Site;;" or similar.

Yep. #load "file-name";; or #use "file-name";; depending on your
needs. Then do a open Module or Module.function. See ocaml doc for
details.

Yours,
david
-- 
 David Mentré <dmentre@linux-france.org>

-------------------
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:[~2004-09-11 16:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-10 22:28 Malte Obbel Forsberg
2004-09-11 16:13 ` David MENTRE [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=87fz5ovl4q.fsf@linux-france.org \
    --to=dmentre@linux-france.org \
    --cc=caml-list@inria.fr \
    --cc=malte@unix.se \
    /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).