Unqual fails with pointer?

Namespace rswhite4 at googlemail.com
Thu Jun 13 14:32:18 PDT 2013


----
import std.traits : Unqual;

void main() {
	static assert(is(Unqual!int == int));
	static assert(is(Unqual!(const int) == int));
	static assert(is(Unqual!(immutable int) == int));
	static assert(is(Unqual!(shared int) == int));
	static assert(is(Unqual!(shared(const int)) == int));
	static assert(is(Unqual!int* == int*));
	static assert(is(Unqual!(const int*) == int*)); /// Error: 
static assert  (is(const(int)* == int*)) is false
}
----

Is this expected?


More information about the Digitalmars-d-learn mailing list