[Issue 11998] writeln with string enum outputs the enum name, not the string

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon Jan 27 14:23:38 PST 2014


https://d.puremagic.com/issues/show_bug.cgi?id=11998



--- Comment #3 from Martin Nowak <code at dawg.eu> 2014-01-27 14:23:35 PST ---
Maybe I was too fast with this, I just expected a different result.

With anonymous enums it works btw.

enum name1 = "printThis";
enum
{
    name2 = "foo",
    name3 = "bar",
}

void main()
{
    import std.stdio : writeln;
    writeln(name1, name2, name3);
}

http://dpaste.dzfl.pl/39b780cc

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list