diff --git a/c/c.go b/c/c.go index 8d6a3ea..9cb38db 100644 --- a/c/c.go +++ b/c/c.go @@ -26,14 +26,9 @@ type ( Float = float32 Double = float64 Pointer = unsafe.Pointer + VaList = Pointer FilePtr = *FILE -) -type FILE struct { - Unused [8]byte -} - -type ( Int = int32 Uint = uint32 @@ -46,6 +41,10 @@ type ( UlongLong = uint64 ) +type FILE struct { + Unused [0]byte +} + type integer interface { ~int | ~uint | ~uintptr | ~int32 | ~uint32 | ~int64 | ~uint64 } @@ -69,7 +68,24 @@ type Uint64T = uint64 type IntmaxT = LongLong type UintmaxT = UlongLong -type VaList = Pointer +// ----------------------------------------------------------------------------- + +type DivT struct { + Quot Int + Rem Int +} + +type LdivT struct { + Quot Long + Rem Long +} + +type LldivT struct { + Quot LongLong + Rem LongLong +} + +// ----------------------------------------------------------------------------- //go:linkname Str llgo.cstr func Str(string) *Char diff --git a/c/llcppg.pub b/c/llcppg.pub index e97dbb1..66f8ef8 100644 --- a/c/llcppg.pub +++ b/c/llcppg.pub @@ -16,7 +16,10 @@ T uint32_t Uint32T T uint64_t Uint64T T intmax_t IntmaxT T uintmax_t UintmaxT -T va_list VaList +T div_t DivT +T ldiv_t LdivT +T lldiv_t LldivT T iconv_t IconvT T locale_t LocaleT T option Option +T va_list VaList