github.com/shogo82148/std@v1.22.1-0.20240327122250-4e474527810c/internal/abi/compiletype.go (about) 1 // Copyright 2023 The Go Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style 3 // license that can be found in the LICENSE file. 4 5 package abi 6 7 // CommonSize returns sizeof(Type) for a compilation target with a given ptrSize 8 func CommonSize(ptrSize int) int 9 10 // StructFieldSize returns sizeof(StructField) for a compilation target with a given ptrSize 11 func StructFieldSize(ptrSize int) int 12 13 // UncommonSize returns sizeof(UncommonType). This currently does not depend on ptrSize. 14 // This exported function is in an internal package, so it may change to depend on ptrSize in the future. 15 func UncommonSize() uint64 16 17 // TFlagOff returns the offset of Type.TFlag for a compilation target with a given ptrSize 18 func TFlagOff(ptrSize int) int 19 20 // ITabTypeOff returns the offset of ITab.Type for a compilation target with a given ptrSize 21 func ITabTypeOff(ptrSize int) int