Phobos Members-Tuple function?

Ali Çehreli acehreli at yahoo.com
Sat Jan 19 18:59:29 PST 2013


On 01/19/2013 06:41 PM, Ali Çehreli wrote:

 > class Engine
 > {
 > static bindActors(Actor, string pattern)
 > {
 > writefln(" Binding actor with pattern %s", pattern);
 > }
 > }

How come that function compiles without a return type? The following is 
a bug, right?

class C
{
     static foo()  // <-- no return type; void is assumed
     {}
}

void main()
{
     static assert(is(typeof(C.foo()) == void));
}

Ali



More information about the Digitalmars-d-learn mailing list