"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "test/compilable/mixintype2.d" between
dmd-2.093.0.tar.gz and dmd-2.093.1.tar.gz

About: DMD (Digital Mars D) is the D reference compiler. D is an object-oriented, imperative, multi-paradigm system programming language.

mixintype2.d  (dmd-2.093.0):mixintype2.d  (dmd-2.093.1)
skipping to change at line 37 skipping to change at line 37
static assert(__traits(compiles, mixin(T))); static assert(__traits(compiles, mixin(T)));
static assert(__traits(compiles, mixin("int*"))); static assert(__traits(compiles, mixin("int*")));
static assert(__traits(compiles, mixin(typeof(0)))); static assert(__traits(compiles, mixin(typeof(0))));
} }
struct S { alias T = float*; } struct S { alias T = float*; }
struct ST(X,Y) {} struct ST(X,Y) {}
void foo(alias t)() {} void foo(alias t)() {}
/**************************************************/
// https://issues.dlang.org/show_bug.cgi?id=21074
alias Byte = ubyte;
alias Byte2(A) = ubyte;
alias T0 = mixin(q{const(Byte)})*;
alias T1 = mixin(q{const(Byte[1])})*;
alias T2 = mixin(q{const(Byte2!int)})*;
alias T3 = mixin(q{const(mixin(Byte2!int))})*;
alias T4 = mixin(q{const(mixin("__traits(getMember, S, \"T\")"))})*;
alias T5 = const(mixin(q{Byte}))*;
alias T6 = const(mixin(q{immutable(Byte)}))*;
alias T7 = const(mixin(q{shared(Byte)}))*;
alias T8 = const(mixin(q{Byte*}));
// the following tests now work
static assert(is(T0 == const(ubyte)*));
static assert(is(T1 == const(ubyte[1])*));
static assert(is(T2 == const(ubyte)*));
static assert(is(T3 == const(ubyte)*));
static assert(is(T4 == const(float*)*));
static assert(is(T5 == const(ubyte)*));
static assert(is(T6 == immutable(ubyte)*));
static assert(is(T7 == const(shared(ubyte))*));
static assert(is(T8 == const(ubyte*)));
// this doesn't work but I'll file a new issue
/*
alias T8 = mixin(q{immutable(__traits(getMember, S, "T"))})*;
static assert(is(T8 == immutable(float*)*));
*/
 End of changes. 1 change blocks. 
0 lines changed or deleted 0 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)