caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: ygrek <ygrek@autistici.org>
To: Ocaml Mailing List <caml-list@inria.fr>
Subject: Re: [Caml-list] Batteries Included syntax extensions?
Date: Mon, 10 Mar 2014 18:19:36 +0800	[thread overview]
Message-ID: <20140310181936.5d70182a@kiwi.local.tld> (raw)
In-Reply-To: <62822885-676F-4397-9619-A2C390056153@ieee.org>

On Mon, 10 Mar 2014 14:12:07 +0400
Ivan Gotovchits <ivg@ieee.org> wrote:

> By the way, list comprehension is already included in standard ocaml distribution. It is not as mighty as batteries one, and slightly differs in syntax:
> 
> [ x / 2 | x <- [ 2;4;6] ]

Wut?
Can you elaborate on this?

$ ocaml -init -
        OCaml version 4.01.0

# [ x / 2 | x <- [ 2;4;6] ];;
Characters 8-9:
  [ x / 2 | x <- [ 2;4;6] ];;
          ^
Error: Syntax error

-- 

  reply	other threads:[~2014-03-10 10:20 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-07 18:04 Yotam Barnoy
2014-03-07 22:12 ` Simon Cruanes
2014-03-10  9:17   ` Arnaud Spiwack
2014-03-10 10:12     ` Ivan Gotovchits
2014-03-10 10:19       ` ygrek [this message]
2014-03-10 10:43         ` ygrek

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=20140310181936.5d70182a@kiwi.local.tld \
    --to=ygrek@autistici.org \
    --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).