caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: John Whitley <whitley@cse.buffalo.edu>
To: caml-list@inria.fr
Subject: for loops with stride
Date: Wed,  9 Dec 1998 22:21:21 -0500 (EST)	[thread overview]
Message-ID: <13935.15218.91076.707446@hadar.cs.Buffalo.EDU> (raw)


Thanks to everyone who responded to my earlier question re:
composition.  Quite enlightening discussion...  8-)

On a hopefully less controversial note, I'd like to make a suggestion
for an addition to OCaml for-loops.  Consider an optional stride
parameter, as in:

for i = 0 to n-1 by stride do
...
done

At least in certain signal processing code that I'm working with
presently, the above is a common (and highly convenient) pattern.  The
corresponding while loop is simply not as easy to write or understand.

Thanks,
John




             reply	other threads:[~1998-12-11 14:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1998-12-10  3:21 John Whitley [this message]
1998-12-11 15:16 Don Syme

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=13935.15218.91076.707446@hadar.cs.Buffalo.EDU \
    --to=whitley@cse.buffalo.edu \
    --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).