Attributes on static constructors

Jakob Ovrum via Digitalmars-d digitalmars-d at puremagic.com
Sat Feb 6 22:54:24 PST 2016


On Sunday, 7 February 2016 at 06:15:29 UTC, Brian Schott wrote:
> std.socket has a line that looks like this:
>
> shared static this() @system
>
> http://dlang.org/spec/grammar.html#StaticConstructor states 
> that function attributes are only valid on "static" and "shared 
> static".
>
> Compiler bug or spec bug?

I'm not sure what you mean. Looking at the section you linked, it 
looks like the issue is that it states that function attributes 
are only valid for module destructors. Seems like an oversight.



More information about the Digitalmars-d mailing list