Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Re: [Caml-list] Runtime overflow and what to do
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: tim@f...
Subject: Re: [Caml-list] Runtime overflow and what to do
From: Jacques Garrigue <>
>The above can be reduced to one line, without temporary file.
>In fact, I feel more like we would need a "-silent" option, to get rid
>of prompts and types (this is already the default with scripts).
>echo "print_int Sys.word_size;;" | \
>ocaml | grep "^# ." | sed -e "s/# //" -e "s/- :.*//"

The following is simpler and works on Unix systems that have /dev/fd:

   echo "print_int Sys.word_size;;" | ocaml /dev/fd/0

I agree that a "-silent" option would be prettier than this, and it
would work on systems that don't have /dev/fd.

Tim Freeman
GPG public key fingerprint ECDF 46F8 3B80 BB9E 575D  7180 76DF FE00 34B1 5C78 
To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: