<?xml version="1.0"?>
<ErrorDocumentation xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <ErrorName>CS1502</ErrorName>
  <Examples>
    <string>// CS1502: The best overloaded method match for `C.Foo(dynamic)' has some invalid arguments
// Line: 13

static class C
{
	public static void Foo (dynamic d)
	{
	}

	static void Main()
	{
		dynamic d = null;
		Foo (ref d);
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `Test.Test(TestMethod2)' has some invalid arguments
// Line: 8

public class Test
{
	void Foo ()
	{
		new Test (new TestMethod (Foo));
	}

	public Test (TestMethod2 test) {}
}

public delegate void TestMethod ();
public delegate void TestMethod2 (object o);</string>
    <string>// CS1502: The best overloaded method match for `T.Blah(out int)' has some invalid arguments
// Line: 11

using System;

class T {
        static void Blah (out int g) { g = 0; }

        static int Main (string [] args) {
                IntPtr g;
                Blah (out g);
		return (int) g;
        }
}
</string>
    <string>// CS1502:  The best overloaded method match for `System.Windows.Forms.X11Xim.XCreateIC(System.IntPtr, __arglist)' has some invalid arguments
// Line: 16

using System;
using System.Runtime.InteropServices;

namespace System.Windows.Forms
{
        internal class X11Xim
        {
                [DllImport ("libX11", EntryPoint="XCreateIC")]
                internal extern static IntPtr XCreateIC(IntPtr xim, __arglist);

                public static void Main ()
                {
                        XCreateIC (IntPtr.Zero, IntPtr.Zero);
                }
        }
}


</string>
    <string>// CS1502: The best overloaded method match for `X.foo(ref int)' has some invalid arguments
// Line: 8
class X {
	public void foo (ref int blah) {}

	public void bar (ref int baz)
	{
		foo(out baz);
	}

	static void Main ()
	{
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `Global.Test1(int?)' has some invalid arguments
// Line: 8

using System;

class Global {
	static void Main() {
		Console.Write(Test1((decimal?)2));
	}	
	static string Test1(int? value) {
		return "ok";
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `C.TestCall(int, string)' has some invalid arguments
// Line: 13

class C
{
	static void TestCall (int i, string s)
	{
	}
	
	public static void Main ()
	{
		dynamic d = 0;
		TestCall (d, 1);
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `C.Test_C(System.Type, params int[])' has some invalid arguments
// Line: 10

using System;

public class C
{
	public static int Main ()
	{
		return Test_C (typeof (C), null, null);
	}
	
	static int Test_C (Type t, params int[] a)
	{
		return 1;
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `Foo.Test(int, string)' has some invalid arguments
// Line: 14

using System.Runtime.CompilerServices;

public class Foo
{
	public void Test (int arg, [CallerMemberName] string s = null)
	{
	}

	void X ()
	{
		Test ("");
	}
}</string>
    <string>// CS1502: The best overloaded method match for `X.Add(params object[])' has some invalid arguments
// Line: 8

class X
{
	public static void Main ()
	{
		Add (Foo (), Foo ());
	}

	public static void Add (params object[] args)
	{
	}

	static void Foo ()
	{
	}
}</string>
    <string>// CS1502: The best overloaded method match for `T.Blah(out int)' has some invalid arguments
// Line: 11

using System;

class T {
        static void Blah (out int g) { g = 0; }

        static int Main (string [] args) {
                IntPtr g;
                Blah (out g);
		return (int) g;
        }
}
</string>
    <string>// CS1502: The best overloaded method match for `X.X(int)' has some invalid arguments
// Line: 14

public class X {

	public X (int a)
	{
	}
}

class D {
	static void Main ()
	{
		X x = new X ("hola");
	}
}

</string>
    <string>// CS1502: The best overloaded method match for `A.A(System.Collections.Generic.IList&lt;int&gt;[])' has some invalid arguments
// Line: 40
using System;
using System.Collections;
using System.Collections.Generic;

public struct MyStruct : IList&lt;int&gt;
{
	public int this [int x] { get { return 0; } set { return; } }
	public int IndexOf (int x) { return 0; }
	public void Insert (int x, int y) { return; }
	public void RemoveAt (int x) { return; }
	public int Count { get { return 0; } }
	public bool IsReadOnly { get { return false; } }
	public void Add (int x) { return; }
	public void Clear () { return; }
	public bool Contains (int x) { return false; }
	public void CopyTo (int[] x, int y) { return; }
	public bool Remove (int x) { return false; }
	public IEnumerator&lt;int&gt; GetEnumerator() { yield return 0; }
	IEnumerator IEnumerable.GetEnumerator() { yield return 0; }
}

public class A
{
	// This version does not compile:
	public A(IList&lt;int&gt;[] x) { }

	// This version compiles fine, but results in an exception:
	public A(IList&lt;IList&lt;int&gt;&gt; x) { }
}

public class Test
{
	static void Main ()
	{
		MyStruct[] myStructArray = new MyStruct[1];

		Console.WriteLine ("Trying to construct an A...");
		A a = new A (myStructArray);
		Console.WriteLine ("success!");
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `TestCase.TestS(ref object)' has some invalid arguments
// Line: 21

using System;

public struct Struct {
	public int x, y, z;
}

public class TestCase {
	
	public static void Main() {
		
		Struct s = new Struct();
		
		s.x = 1;
		s.y = 2;
		
		System.Console.WriteLine("{0} {1} {2}", s.x, s.y, s.z);
		
		TestS(ref s);
	}	
	
	public static void TestS(ref object ino) {
		System.Console.WriteLine("{0}", ((Struct)(ino)).x);
	}
	
}
</string>
    <string>// CS1502: The best overloaded method match for `foo.p(string, object, object)' has some invalid arguments
// Line: 24

using System;

public class foo
{
	static int intval = 3;

	public static void voidfunc()
	{
	}
	
	static void p (string s, object o1, object o2)
	{
	}
	
	static void p (string s, params object[] o)
	{
	}

	public static void Main()
	{
		p ("Whoops: {0} {1}", intval, voidfunc());
	}
}
</string>
    <string>// CS1502: The best overloaded method match for `System.Console.WriteLine(bool)' has some invalid arguments
// Line: 10
using System;

public class MainClass
{
        public static void Main()
        {
		test MyBug = new test();
                Console.WriteLine (MyBug.mytest());
	}
}

public class   test
{
        public void mytest()
        {
                Console.WriteLine("test");
	}
}


</string>
    <string>// CS1502: The best overloaded method match for `X.M(string)' has some invalid arguments
// Line: 23

delegate void D1 (object o);
delegate void D2 ();

class C
{
	public C (D1 d)
	{
	}
	
	public C (D2 d)
	{
	}
}

class X
{
	void Foo ()
	{
		new C (delegate (object state) {
			M (1);
		});
	}

	void M (string s)
	{
	}
}

</string>
  </Examples>
</ErrorDocumentation>