Mailing list for all users of the OCaml language and system.
 help / color / mirror / Atom feed
From: Matthieu Dubuget <matthieu.dubuget@gmail.com>
To: caml-list@inria.fr
Subject: Re: [Caml-list] Calling OCaml from C - nothing shown on stdout
Date: Tue, 29 Jun 2010 13:52:03 +0200	[thread overview]
Message-ID: <4C29DE63.3040607@gmail.com> (raw)
In-Reply-To: <E51C5B015DBD1348A1D85763337FB6D908F27E@Remus.metastack.local>

-------- Original Message --------
Subject: Re: [Caml-list] Calling OCaml from C - nothing shown on stdout
From: David Allsopp <dra-news@metastack.com>
To: 'Andreas Sommer' <AndiDog@web.de>, 'caml-list@yquem.inria.fr' 
<caml-list@yquem.inria.fr>
Date: 29/06/2010 13:18
>
> 2. Insert a flush stdout statement after each Printf.printf call. Better, create another function using Printf.kprintf which flushes stdout each time:
>      let flushed_printf x = Printf.kprintf (fun s ->  print_string s; flush stdout) in
>      flushed_printf "%s" "Finished with..."
>    

Or use "%!" in your string format to flush.

Salutations

Matt


  reply	other threads:[~2010-06-29 11:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-29 10:44 Andreas Sommer
2010-06-29 10:52 ` [Caml-list] " Erik de Castro Lopo
2010-06-29 11:18 ` David Allsopp
2010-06-29 11:52   ` Matthieu Dubuget [this message]
2010-06-29 12:45   ` Andreas Sommer

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=4C29DE63.3040607@gmail.com \
    --to=matthieu.dubuget@gmail.com \
    --cc=caml-list@inria.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