[Issue 6892] Formatted write with specified length of enum member

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Apr 20 18:54:16 PDT 2012


http://d.puremagic.com/issues/show_bug.cgi?id=6892



--- Comment #6 from Ali Cehreli <acehreli at yahoo.com> 2012-04-20 18:55:09 PDT ---
The problem at comment 5 can be reduced to this:

import std.stdio;

void main()
{
    writefln("%f", 42); // COMPILATION ERROR
}

It looks like an integral cannot be matched to a floating point format
specifier. (The same problem with "%g", etc.)

I have mixed feelings about this. Although 42 is definitely not a floating
point type, it is implicitly converted to one according to language rules.

-- 
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