caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Ravi Chamarty <ravi@ittc.ukans.edu>
To: Jocelyn Serot <jserot@lasmea.univ-bpclermont.fr>
Cc: caml-list@inria.fr
Subject: Re: [Caml-list] Caml Wrappers
Date: Thu, 8 Mar 2001 12:53:24 -0600 (CST)	[thread overview]
Message-ID: <Pine.LNX.4.10.10103081239270.19181-100000@elroy.ittc.ukans.edu> (raw)
In-Reply-To: <15015.18070.504662.128258@mistral.univ-bpclermont.fr>


Hi,

 Thanks for all the help. I looked up at both the CamlIDL and the dbm
stuff . Both of them helped a lot. I even tried a few wrappers similar to
the dbm library. However, since my C library is quite extensive, using
CamlIDL seems to be a good idea.

 Can anyone please spare a few IDL samples to help me get a good idea of
it.

Thanks again for all the help
Ravi
 



On Thu, 8 Mar 2001, Jocelyn Serot wrote:

> Ravi Chamarty writes:
> > 
> > Hi ,
> > 
> >  I am trying to write OCaml interfaces around a C library.  I tried
> > looking at the Unix library and trying to understand it. However, I have
> > much complex data types to deal with.I was wondering if anyone could help
> > me out. 
> > 
> > Here is a signature of one of the C functions:
> > 
> > an_flow_t * 
> > an_flow_create(void *mem, an_cred_t *cred, an_cpuspec_t *cspec,
> > 		an_memspec_t *mspec, an_flowinit_func_t init, 
> > 		void *initarg, an_flowterm_func_t term)
> > 
> > 
> > Each of these types are complex structures in C. How do I represent these
> > in OCaml. Is it useful to use classes and methods? Or do I use abstract
> > types to represent them ?
> > 
> > An example of one of these structures is given below:
> > 
> > [...]
> > I would be grateful for any help.
> > 
> > Thanks
> > Ravi
> > 
> 
> Did you have a look a Camlidl (http://pauillac.inria.fr/caml/camlidl) ?
> It can generate rather complex stub code for you.
> 
> Jocelyn
> 
> -- 
> E-mail: Jocelyn.Serot@l_a_s_m_e_a.u_n_i_v-bpclermont.fr .....................
> S-mail: LASMEA - UMR 6602 CNRS, Universite Blaise Pascal, 63177 Aubiere cedex
> Tel: (33) 04 73.40.73.30 - Fax: (33) 04 73.40.72.62 .........................
> Valid e-mail: remove underscores (sorry, this is prevention against junk mail
> 


-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr


  reply	other threads:[~2001-03-08 18:53 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-03-07 23:58 Ravi Chamarty
2001-03-08  2:39 ` Jacques Garrigue
2001-03-08  8:45 ` Jocelyn Serot
2001-03-08 18:53   ` Ravi Chamarty [this message]
2001-03-08 15:26 ` John Max Skaller

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=Pine.LNX.4.10.10103081239270.19181-100000@elroy.ittc.ukans.edu \
    --to=ravi@ittc.ukans.edu \
    --cc=caml-list@inria.fr \
    --cc=jserot@lasmea.univ-bpclermont.fr \
    /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).