unique_name sheningans

This commit is contained in:
Krzosa Karol
2023-04-01 20:32:29 +02:00
parent e8f82f643a
commit 96ce6765fe
7 changed files with 18 additions and 22 deletions

View File

@@ -53,7 +53,6 @@ MultipleArgs :: (): Tuple(int, F32)
PolyLambda :: ($T: Type): T
return 32
GetCount :: (a: int): int
return a

View File

@@ -1,16 +1,10 @@
MA :: #import "Arena.core"
/*
PushStruct :: (a: *MA.Arena, $T: Type): *$T
size := size_of(Type)
result := PushSize(a, size)
return result
*/
PushStruct :: (a: *MA.Arena, type: Type): *void
ti := GetTypeInfo(type)
result := MA.PushSize(a, ti.size->U64)
return result
PushStruct :: (a: *MA.Arena, $T: Type): *T
v: T
size := SizeOf(v)
result := MA.PushSize(a, size->U64)
return result->*T
main :: (argc: int, argv: **char): int
arena: MA.Arena