public class Test { public static void Main () { } public static void Foo (object arg) { string result = arg as string ?? ""; } }