mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Tests for new visibility rules
This commit is contained in:
parent
75dd1a4213
commit
46a7e0568d
4 changed files with 124 additions and 0 deletions
|
@ -3,6 +3,11 @@ using System.Collections;
|
|||
|
||||
namespace LibA
|
||||
{
|
||||
struct LibAStruct
|
||||
{
|
||||
int mA;
|
||||
}
|
||||
|
||||
interface IVal
|
||||
{
|
||||
int Val
|
||||
|
@ -33,6 +38,25 @@ namespace LibA
|
|||
{
|
||||
return lhs == rhs;
|
||||
}
|
||||
|
||||
public static int GetOverload0<T>() where T : var
|
||||
{
|
||||
T val = default;
|
||||
return Overload0(val);
|
||||
}
|
||||
}
|
||||
|
||||
struct Handler
|
||||
{
|
||||
public static int Handle(Object obj)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
public static int HandleT<T>(T val) where T : var
|
||||
{
|
||||
return Handle(val);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -74,4 +98,17 @@ class LibClassB
|
|||
{
|
||||
return LibClassA.GetVal3(val);
|
||||
}
|
||||
}
|
||||
|
||||
static
|
||||
{
|
||||
public static int Overload0(Object a)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
public static int Overload0(int8 a)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue