[Issue 20410] ReplaceTypeUnless replaces enums with their basetype
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Fri Nov 22 15:21:24 UTC 2019
https://issues.dlang.org/show_bug.cgi?id=20410
Paul Backus <snarwin+bugzilla at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |snarwin+bugzilla at gmail.com
Component|phobos |dmd
--- Comment #2 from Paul Backus <snarwin+bugzilla at gmail.com> ---
Looks like a bug in the is expression. The "true" below ought to be "false":
enum Enum : string { foo = "bar" }
pragma(msg, is(Enum == string)); // false
pragma(msg, is(Enum == T[], T)); // true
pragma(msg, T); // immutable(char)
--
More information about the Digitalmars-d-bugs
mailing list