Bug in D!!!

EntangledQuanta via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Sep 1 12:33:21 PDT 2017


On Friday, 1 September 2017 at 19:25:53 UTC, Adam D Ruppe wrote:
> On Friday, 1 September 2017 at 18:17:22 UTC, EntangledQuanta 
> wrote:
>> I get an access violation, changed the code to
>
> What is the rest of your code? access violation usually means 
> you didn't new the class...

No, that is the code! I added nothing. Try it out and you'll see. 
I just upgraded to released dmd too.


alias I(A...) = A;

interface Foo {
         static foreach(T; I!(int, float))
                 void set(T t); // define virt funcs for a list of 
types
}

class Ass : Foo {
         static foreach(T; I!(int, float))
                 void set(T t) {
                         // simplement
                 }
}

void main()
{

}

try it.




More information about the Digitalmars-d-learn mailing list