mirror of
https://github.com/github/codeql.git
synced 2025-12-17 01:03:14 +01:00
C#: Add some attributes test example code with overload resolution priority attribute.
This commit is contained in:
@@ -161,3 +161,15 @@ public class MyExperimentalClass
|
||||
[Experimental("MyExperimentalMethodId")]
|
||||
public void MyExperimentalMethod() { }
|
||||
}
|
||||
|
||||
public class MyOverloadResolutionClass
|
||||
{
|
||||
[OverloadResolutionPriority(-1)]
|
||||
public void M(int[] arr) { }
|
||||
|
||||
[OverloadResolutionPriority(1)]
|
||||
public void M(IEnumerable<int> e) { }
|
||||
|
||||
[OverloadResolutionPriority(2)]
|
||||
public void M(ReadOnlySpan<int> s) { }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user