Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Keyan Zahedi <ml@pulsschlag.net>
To: "Stéphane Glondu" <steph@glondu.net>
Cc: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Setting function in a class
Date: Mon, 19 Jul 2010 10:01:13 +0200	[thread overview]
Message-ID: <5765205C-8A2E-447E-9A88-D93C85DF0537@pulsschlag.net> (raw)
In-Reply-To: <4C4400B9.9040401@glondu.net>

hi,

this is indeed my code. being sure, that my code is correct, i was able to locate the problem somewhere else :)

thanks!
keyan

On 19 Jul 2010, at 09:37, Stéphane Glondu wrote:

> Le 19/07/2010 09:30, Keyan Zahedi a écrit :
>> class myclass =
>> object
>> val mutable _myfunc = (* a function of type string -> bool)
>> method set_myfunc f = _myfunc <- f
>> method my_func f = _myfunc f
>> ;;
> 
> I am not sure of what blocks you. Just making your snippet syntactically
> correct works:
> 
> class myclass =
> object
> val mutable _myfunc = fun (s:string) -> true
> method set_myfunc f = _myfunc <- f
> method my_func f = _myfunc f
> end
> ;;
> 
> 
> Cheers,
> 
> -- 
> Stéphane
> 


      reply	other threads:[~2010-07-19  8:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-19  7:30 Keyan Zahedi
2010-07-19  7:37 ` [Caml-list] " Stéphane Glondu
2010-07-19  8:01   ` Keyan Zahedi [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=5765205C-8A2E-447E-9A88-D93C85DF0537@pulsschlag.net \
    --to=ml@pulsschlag.net \
    --cc=caml-list@yquem.inria.fr \
    --cc=steph@glondu.net \
    /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