Incorrect generics

using System;
using System.Collections.Generic;
using System.Text;

namespace ConsoleApplication9
{
public abstract class A
{
public abstract void Print(string s);
}

public class OA : A
{
public override void Print(string s)
{

}
}

public class B:A where T: A, new() { public override void Print(string s) { } } public class C:B where T:A, new() { } public class M { public static void Main() { C c = new C]]>();
c.Print("sdfsdf");
}
}

}

1 comment
Comment actions Permalink

Fixed in build 216

--
Eugene Pasynkov
Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"
"Airex" wrote in message news:op.s4ah1eupyg18dx@w-skachkovsky.lana.vl.net.ua... using System; using System.Collections.Generic; using System.Text; namespace ConsoleApplication9 { public abstract class A { public abstract void Print(string s); } public class OA : A { public override void Print(string s) { } } public class B:A where T: A, new() { public override void Print(string s) { } } public class C:B where T:A, new() { } public class M { public static void Main() { C c = new C]]>();
c.Print("sdfsdf");
}
}

}


0

Please sign in to leave a comment.