a575963da9
Former-commit-id: da6be194a6b1221998fc28233f2503bd61dd9d14
29 lines
509 B
C#
29 lines
509 B
C#
// Compiler options: -warnaserror
|
|
|
|
using System;
|
|
using System.Reflection;
|
|
|
|
sealed class X
|
|
{
|
|
~X ()
|
|
{
|
|
Foo ();
|
|
}
|
|
|
|
public void Foo ()
|
|
{
|
|
}
|
|
|
|
public static int Main ()
|
|
{
|
|
foreach (var m in typeof (X).GetMethods (BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.DeclaredOnly)) {
|
|
Console.WriteLine (m.Name);
|
|
Console.WriteLine (m.Attributes);
|
|
if (m.Attributes != (MethodAttributes.Virtual | MethodAttributes.Family | MethodAttributes.HideBySig))
|
|
return 1;
|
|
}
|
|
|
|
return 0;
|
|
}
|
|
}
|