using System;
interface P {}
struct S : P {};
static class C
{
static void foo<T>(T value) where T : P {
bar(value);
}
static void bar(S _) { Console.Write("S call\n"); }
static void bar<T>(T _) where T : P { Console.Write("P call\n"); }
public static void test() {
S s;
bar(s);
foo(s);
public class Program
public static void Main() { C.test(); }