mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 04:22:20 +02:00
Mintest updates
This commit is contained in:
parent
5879469933
commit
2fbaf061ef
7 changed files with 104 additions and 81 deletions
|
@ -30,6 +30,12 @@ public enum QIntDisplayType
|
|||
COUNT
|
||||
}
|
||||
|
||||
[CRepr]
|
||||
public struct ALLEGRO_COLOR
|
||||
{
|
||||
public float r, g, b, a;
|
||||
}
|
||||
|
||||
namespace Hey.Dude.Bro
|
||||
{
|
||||
class TestClass
|
||||
|
@ -66,13 +72,21 @@ namespace Hey.Dude.Bro
|
|||
#if BF_64_BIT
|
||||
[Import(@"C:\Beef\BeefTools\TestDLL\x64\Debug\TestDLL.dll"), LinkName("Test2")]
|
||||
public static extern void Test2(int32 a, int32 b, int32 c, int32 d);
|
||||
|
||||
[Import(@"C:\Beef\BeefTools\TestDLL\x64\Debug\TestDLL.dll"), LinkName("Test3")]
|
||||
public static extern void Test3(void* ptr, ALLEGRO_COLOR color);
|
||||
#else
|
||||
[Import(@"C:\Beef\BeefTools\TestDLL\Debug\TestDLL.dll"), LinkName("Test2")]
|
||||
public static extern void Test2(int32 a, int32 b, int32 c, int32 d);
|
||||
|
||||
[Import(@"C:\Beef\BeefTools\TestDLL\Debug\TestDLL.dll"), LinkName("Test3")]
|
||||
public static extern void Test3(void* ptr, ALLEGRO_COLOR color);
|
||||
|
||||
[Import(@"C:\Beef\BeefTools\TestDLL\Debug\TestDLL.dll"), LinkName("Test4")]
|
||||
public static extern void Test4(void* ptr, ALLEGRO_COLOR* color);
|
||||
#endif
|
||||
|
||||
[Import(@"C:\Beef\BeefTools\TestDLL\x64\Debug\TestDLL.dll"), CLink]
|
||||
public static extern void Test4(int32 a, int32 b);
|
||||
|
||||
|
||||
|
||||
static uint32 sStaticVar = 234;
|
||||
|
@ -223,15 +237,6 @@ namespace Hey.Dude.Bro
|
|||
|
||||
public static int Main(String[] args)
|
||||
{
|
||||
function void() func = => Florgs;
|
||||
int32 val = (int32)(int)(void*)func;
|
||||
|
||||
//void* ptr = "Hey";
|
||||
//val = (int32)ptr;
|
||||
|
||||
|
||||
//Test2(1, 2, val, 4);
|
||||
|
||||
Blurg.Hey();
|
||||
return 1;
|
||||
}
|
||||
|
|
|
@ -1,24 +1,17 @@
|
|||
// more text at the end of the first line. This is more text.
|
||||
|
||||
using System;
|
||||
|
||||
#define SMz
|
||||
|
||||
#if SM
|
||||
typealias int_test = int32;
|
||||
#else
|
||||
typealias int_test = int64;
|
||||
#endif
|
||||
|
||||
struct Floof
|
||||
class Pooble
|
||||
{
|
||||
public static int32 Hey()
|
||||
public void Test(int abcdefgh, int abcdefgh2, int abcdefgh3, int abcdefgh4, int abcdefgh5, int abcdefgh6, int abcdefgh7, int abcdefgh8)
|
||||
{
|
||||
Result<int> res = 123;
|
||||
switch (res)
|
||||
{
|
||||
case .Ok(let val):
|
||||
default:
|
||||
}
|
||||
}
|
||||
|
||||
return 123;
|
||||
public static float sVal = 9;
|
||||
|
||||
public static mixin Zorp(var z)
|
||||
{
|
||||
z * sVal
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,56 +1,43 @@
|
|||
//using Squarf;
|
||||
|
||||
//GORB
|
||||
#pragma warning disable 168
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Threading;
|
||||
using System.Collections.Generic;
|
||||
|
||||
#region EnumA Crapsos
|
||||
[AllowDuplicates]
|
||||
enum EnumA
|
||||
struct Smibbs
|
||||
{
|
||||
Abo = 1,
|
||||
Boop = _*2,
|
||||
Croop = _*2,
|
||||
|
||||
Zoop = 1
|
||||
public int16 mX = 11;
|
||||
public int16 mY = 22;
|
||||
public int16 mZ = 33;
|
||||
}
|
||||
|
||||
struct StructA
|
||||
namespace PropertyStructCrash
|
||||
{
|
||||
public int mA;
|
||||
public int mB;
|
||||
struct B
|
||||
{
|
||||
public int c;
|
||||
}
|
||||
|
||||
struct A
|
||||
{
|
||||
public B Prop { get; set; }
|
||||
}
|
||||
|
||||
class Program
|
||||
{
|
||||
public static void Main()
|
||||
{
|
||||
var c = '¥';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#region Blurg
|
||||
struct Blurg
|
||||
{
|
||||
static mixin MixA(var sa2)
|
||||
public static void Hey()
|
||||
{
|
||||
sa2.mA++;
|
||||
}
|
||||
|
||||
static mixin MixB(mut StructA sa2)
|
||||
{
|
||||
sa2.mA++;
|
||||
}
|
||||
|
||||
static void MethodA(mut StructA sa)
|
||||
{
|
||||
MixA!(sa);
|
||||
//MixB!(mut sa);
|
||||
}
|
||||
|
||||
public static int32 Hey()
|
||||
{
|
||||
StructA sa = .();
|
||||
sa.mA = 123
|
||||
|
||||
|
||||
return (int32)123;
|
||||
PropertyStructCrash.Program.Main();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue