scope as storage class

Namespace rswhite4 at googlemail.com
Thu Sep 27 05:01:39 PDT 2012


So you mean this code should give an error?

import std.stdio;

class A { }

A ga;

void foo(scope A a) {
	ga = a;
}

void main() {
	A a = new A();
	
	foo(a);
}


More information about the Digitalmars-d-learn mailing list