blob: e48b76fdf4edcc4af76101c779e20b1bcb5e739f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
// Compiler options: -t:library
using System;
using System.Runtime.CompilerServices;
public class CallerTest
{
public static int Foo ([CallerMemberName]string arg1 = null, [CallerFilePath] string arg2 = null, [CallerLineNumberAttribute] int arg3 = -1)
{
if (arg1 == null)
return 1;
if (arg2 == null)
return 2;
if (arg3 == -1)
return 3;
return 0;
}
}
|