Integral literals with Exp?
matovitch via Digitalmars-d
digitalmars-d at puremagic.com
Mon Sep 15 02:05:09 PDT 2014
On Saturday, 13 September 2014 at 07:23:39 UTC, bearophile wrote:
> Is it a good idea to accept code like this, to shorten some
> constants?
>
> void main() {
> int x = 1e6;
> }
>
> Bye,
> bearophile
Well, I guess it wouldn't help the lexer. To be consistent :
int x = 1.73e2;
should be allowed but not
int y = 1.73e1;
Not a good idea IMHO.
More information about the Digitalmars-d
mailing list