From: Daniel de Rauglaudre <daniel.de_rauglaudre@inria.fr>
To: caml-list@inria.fr
Subject: Re: [Caml-list] semi-colons and begin
Date: Thu, 5 Apr 2001 05:53:48 +0200 [thread overview]
Message-ID: <20010405055348.A4758@verdot.inria.fr> (raw)
In-Reply-To: <4.3.2.7.2.20010404142255.0338a1c0@shell16.ba.best.com>; from checker@d6.com on Wed, Apr 04, 2001 at 02:33:03PM -0700
Hi,
On Wed, Apr 04, 2001 at 02:33:03PM -0700, Chris Hecker wrote:
> I must admit I'm still slightly confused about the semicolon thing,
> even after writing a fair amount of caml code. The current sticking
> point is that
>
> # if false then print_int 2; print_int 3;;
> 3- : unit = ()
Do you want me to confuse you more? Try this:
# if false then let _ = () in print_int 2; print_int 3;;
> # if false then print_int 2; print_int 3 else ();;
> Characters 39-43:
> Syntax error
And this one:
# if false then let _ = () in print_int 2; print_int 3 else print_int 4;;
And this situation:
if blahblah then
thing1;
thing2;
thing3;
I decide to add a let..in for the thing1.
What you see:
if blahblah then
let x = e in
thing1;
thing2;
thing3;
What you get:
if blahblah then
let x = e in
thing1;
thing2;
thing3;
--
Daniel de RAUGLAUDRE
daniel.de_rauglaudre@inria.fr
http://cristal.inria.fr/~ddr/
-------------------
To unsubscribe, mail caml-list-request@inria.fr. Archives: http://caml.inria.fr
next prev parent reply other threads:[~2001-04-05 3:53 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-04-04 21:33 Chris Hecker
2001-04-04 22:40 ` Gerd Stolpmann
2001-04-04 23:32 ` Chris Hecker
2001-04-05 1:03 ` mahamud
2001-04-05 3:48 ` Brian Rogoff
2001-04-05 6:05 ` David Brown
2001-04-06 9:33 ` Gerd Stolpmann
2001-04-05 3:35 ` Michael Hicks
2001-04-05 3:53 ` Daniel de Rauglaudre [this message]
2001-04-05 6:23 ` Mattias Waldau
2001-04-05 17:34 ` Pierre Weis
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=20010405055348.A4758@verdot.inria.fr \
--to=daniel.de_rauglaudre@inria.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