[Issue 11661] New: Meaningless error: "a struct is not a valid initializer for a void function()"
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sun Dec 1 18:09:50 PST 2013
https://d.puremagic.com/issues/show_bug.cgi?id=11661
Summary: Meaningless error: "a struct is not a valid
initializer for a void function()"
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: rejects-valid
Severity: normal
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: k.hara.pg at gmail.com
--- Comment #0 from Kenji Hara <k.hara.pg at gmail.com> 2013-12-01 18:09:48 PST ---
This code should work, but doesn't.
void main()
{
void delegate() dg = {}; // OK
void function() fp = {}; // NG
}
test.d(4): Error: a struct is not a valid initializer for a void function()
--
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