caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
From: Erik de Castro Lopo <mle+ocaml@mega-nerd.com>
To: caml-list@inria.fr
Subject: Re: [Caml-list] Float literals
Date: Wed, 27 Jun 2007 06:38:26 +1000	[thread overview]
Message-ID: <20070627063826.e6b3ddbd.mle+ocaml@mega-nerd.com> (raw)
In-Reply-To: <46817245.4020305@gmail.com>

Edgar Friendly wrote:

> But it doesn't match some expectations I have about float literals.  The
> following are all float literals:
> 
> 3.14      (* no problem here *)
> 6.022E23  (* no problem here *)
> 9.109e-31 (* still no problem *)
> 2.        (* a float - blank decimal part *)
> 1e6       (* an integer?  no, a float without a .  Problem.*)
> 13        (* valid as a float, according to the above definition *)
> 
> Does anyone else find the last two cases kind of odd?

I do not find the second last case odd (all languages I have used
consider that a float), but I do for the last one.

Erik
-- 
-----------------------------------------------------------------
Erik de Castro Lopo
-----------------------------------------------------------------
"Neither noise nor information is predictable."
  -- Ray Kurzweil


  reply	other threads:[~2007-06-26 20:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-06-26 20:08 Edgar Friendly
2007-06-26 20:38 ` Erik de Castro Lopo [this message]
2007-06-27  4:10   ` [Caml-list] " Jon Harrop
2007-06-27  4:48     ` Edgar Friendly
2007-06-26 20:48 ` Robert Roessler

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=20070627063826.e6b3ddbd.mle+ocaml@mega-nerd.com \
    --to=mle+ocaml@mega-nerd.com \
    --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).