caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: "Warp" <warplayer@free.fr>
To: "OCaml" <caml-list@inria.fr>
Subject: [Caml-list] input_line is blocking
Date: Fri, 3 May 2002 14:18:13 +0200	[thread overview]
Message-ID: <001101c1f29c$98e4b570$5000a8c0@warp> (raw)

Hi
I'm running "ocamlc" by using Unix.open_process_full in order to write an
automatic compiler.
Right now, it's working fine, but I got now a problem with input_line :

after running open_process_full , i'm first reading all its stdout lines of
the process until End_of_file is raised, then all its stderr lines using the
same function.

It has work fine for few weeks now, but now I found that in some cases
input_line will block, not raising End_of_file.
Actually I got the following errors (on purpose ! ) in one of my test files
:

File "player.ml", line 16, characters 6-66:
Warning: this expression should have type unit.
The implementation player.ml does not match the interface player.cmi :
Modules do not match:
  sig
     type 'a t = 'a array
     ...
     ....
  end
is not included in
   sig
     ...........
   end
The field 'c_value' is required but not provided

I tried to correct few errors, and if I correct enough of them, it works
 the call to input_line on the stdout where NO DATA is written is raising
End_of_file ) , but if correct some other errors, I won't work again...

Perhaps something to do with bufferization ?
If ocamlc generates too much data on stderr, then he waits for the calling
process to read that data, but the process is currently reading on its
stdout.... And vice-versa for ocamldep ( which generates a lot of data on
its stdout )

Any help would be apprecied

Nicolas Cannasse

-------------------
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:[~2002-05-03 12:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-05-03 12:18 Warp [this message]
2002-05-03 14:13 ` Oliver Bandel
2002-05-03 17:26 ` Remi VANICAT
2002-05-05 13:09 ` Gerd Stolpmann

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='001101c1f29c$98e4b570$5000a8c0@warp' \
    --to=warplayer@free.fr \
    --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;
as well as URLs for NNTP newsgroup(s).