linux-packaging-mono/mcs/tests/test-partial-07.cs
Jo Shields a575963da9 Imported Upstream version 3.6.0
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
2014-08-13 10:39:27 +01:00

38 lines
590 B
C#

using System;
using System.Reflection;
using System.Runtime.InteropServices;
[Test2]
public partial class Test
{ }
[AttributeUsage(AttributeTargets.Struct)]
public partial class TestAttribute: Attribute
{
}
[AttributeUsage(AttributeTargets.All)]
public partial class Test2Attribute: Attribute
{
}
[TestAttribute]
public struct Test_2 {
}
class X
{
public static int Main ()
{
if (Attribute.GetCustomAttributes (typeof (Test)).Length != 1)
return 1;
if (Attribute.GetCustomAttributes (typeof (Test_2)).Length != 1)
return 1;
Console.WriteLine ("OK");
return 0;
}
}