[Issue 17597] New: std.typecons.Typedef cannot be instantiated with void
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Wed Jul 5 03:42:27 PDT 2017
https://issues.dlang.org/show_bug.cgi?id=17597
Issue ID: 17597
Summary: std.typecons.Typedef cannot be instantiated with void
Product: D
Version: D2
Hardware: x86_64
OS: Linux
Status: NEW
Severity: normal
Priority: P1
Component: phobos
Assignee: nobody at puremagic.com
Reporter: razvan.nitu1305 at gmail.com
I want to create a typedef from void :
alias MyVoid = Typedef!void;
When I try to compile the code, it fails with the error message:
std/typecons.d(6328): Error: void does not have a default initializer
That may be so, but I should be able to create a Typedef anyway. I think that
the best way to go here is to make the init null for types that do not have
init values.
This is currently blocking [1] due to the fact that an alias to void is used
instead of a typedef.
[1] https://issues.dlang.org/show_bug.cgi?id=16735
--
More information about the Digitalmars-d-bugs
mailing list