`ref T` should be a type!!
Walter Bright
newshound2 at digitalmars.com
Tue Apr 2 08:05:25 UTC 2019
On 4/1/2019 4:04 PM, Atila Neves wrote:
> It's a good point though that void is
> treated differently in C's type system.
Void is treated as a degenerate type, and as you say, rejected constructs like
arrays of void are rejected because they are nonsense. Arrays of functions are
similarly rejected.
Not at all like what goes on with ref in C++, because an array of refs could
have perfectly reasonable semantics. But they are not allowed in C++, because
ref is a storage class pretending to be a type.
More information about the Digitalmars-d
mailing list