/trunk/Examples/test-suite/csharp/varargs_runme.cs

# · C# · 20 lines · 13 code · 6 blank · 1 comment · 6 complexity · 3662c0626b0a031235cd5a4f40f2d2d8 MD5 · raw file

  1. // varargs test
  2. using System;
  3. using varargsNamespace;
  4. public class varargs_runme {
  5. public static void Main() {
  6. if (varargs.test("Hello") != "Hello")
  7. throw new Exception("Failed");
  8. Foo f = new Foo("Greetings");
  9. if (f.str != "Greetings")
  10. throw new Exception("Failed");
  11. if (f.test("Hello") != "Hello")
  12. throw new Exception("Failed");
  13. }
  14. }