[Issue 9357] Floating-point literal should always be printed with a period
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Jan 20 10:27:25 PST 2013
http://d.puremagic.com/issues/show_bug.cgi?id=9357
--- Comment #3 from Andrej Mitrovic <andrej.mitrovich at gmail.com> 2013-01-20 10:27:24 PST ---
(In reply to comment #2)
> Is this enhancement request only about error messages?
>
>
> This prints "1":
>
> import std.stdio: writeln;
> void main() {
> double x = 1.0;
> writeln(x);
> }
>
>
> While in Python it always prints the leading ".0":
>
> >>> x = 1.0
> >>> x
> 1.0
>
> I'd like writeln() to do the same. It helps tell part FP from integral values
> in printouts, etc.
Nice catch. Please file this as another report since it's a library issue, I'll
rename the current issue so it's obvious it's a compiler issue.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list