What is the postfix for min long value?
Zaydek via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue May 30 11:03:45 PDT 2017
On Tuesday, 6 October 2015 at 15:16:13 UTC, tcak wrote:
> While writing max ulong value, I added the "u" postfix. So
> compiler accepted it as ulong value (That's my interpretation
> if correct on compiler's side).
>
> writeln( 18_446_744_073_709_551_615u );
>
> But when I try to print out minimum value of long, compiler says
> Error: signed integer overflow
>
> writeln( -9_223_372_036_854_775_808 );
>
> In case that is the wrong value, I checked it with writeln(
> long.min ); already.
>
> Do I need to put a postfix for that number? I checked
> documentation by searching "dlang integer" etc, but couldn't
> have found any information/anything about postfix at all.
See above ^^ :D
More information about the Digitalmars-d-learn
mailing list