On Sunday, 2 October 2016 at 15:54:38 UTC, Satoshi wrote:
Hello,
why
pure @safe nothrow @nogc struct Point {
}
isn't same as
struct Point {
pure: @safe: nothrow: @nogc:
}
??
This is not specified but attributes aren't applied to the scope
created by the declaration. Which is a good thing, for example
with the visibility attributes it would be a problem, imagine the
following declarations:
struct Foo(T)
{
private struct Range // imagine that private as a inner
"private:"
{
void popFront(); // would be private !!
bool empty(); // would be private !!
T front(); // would be private !!
}
}
So this is really not something anyone would want.