abiBasic fix

This commit is contained in:
xushiwei
2024-05-24 07:51:41 +08:00
parent 1162a5f916
commit 88004cac76
12 changed files with 924 additions and 380 deletions

View File

@@ -22,10 +22,25 @@ import (
"fmt"
"go/types"
"hash"
"github.com/goplus/llgo/internal/abi"
)
// -----------------------------------------------------------------------------
func BasicKind(t *types.Basic) abi.Kind {
kind := t.Kind()
switch kind {
case types.String:
return abi.String
case types.UnsafePointer:
return abi.UnsafePointer
}
return abi.Kind(kind)
}
// -----------------------------------------------------------------------------
type Kind int
const (