mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-21 21:38:52 +00:00
18 lines
No EOL
410 B
C#
18 lines
No EOL
410 B
C#
using System;
|
|
|
|
namespace IL2CPU.Tests.Tests.Events.CustomDelegate {
|
|
public delegate void OurDelegateTest(int aValue);
|
|
public static class CustomDelegate {
|
|
private static int ReturnCode;
|
|
private static void Handler(int aValue) {
|
|
ReturnCode -= aValue;
|
|
}
|
|
|
|
static int Main() {
|
|
ReturnCode = 5;
|
|
OurDelegateTest xHandler = Handler;
|
|
xHandler(5);
|
|
return ReturnCode;
|
|
}
|
|
}
|
|
} |