[Issue 19935] hasUDA and getUDAs ignore UDA with a custom string type
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Jun 3 06:00:31 UTC 2019
https://issues.dlang.org/show_bug.cgi?id=19935
Simen Kjaeraas <simen.kjaras at gmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
CC| |simen.kjaras at gmail.com
Resolution|--- |DUPLICATE
--- Comment #1 from Simen Kjaeraas <simen.kjaras at gmail.com> ---
The issue here is the pointer in My_String. We can easily provoke an error
message with this line:
// Error: cannot use non-constant CTFE pointer in an
// initializer Attribute1(My_String(0L, &""[0]))
enum a = Attribute1(make_my_string(""));
The root issue here is issue 11268.
One might think the workaround is to make data immutable, but sadly that gives
the same error message.
*** This issue has been marked as a duplicate of issue 11268 ***
--
More information about the Digitalmars-d-bugs
mailing list