func newStructWithoutFields(t *gcc.Struct) *Struct { s := &Struct{ baseCNamer: newExported(t), baseEqualType: baseEqualType{ cgoName: cgoName(t.CName()), size: t.Size(), conv: ValConv, }, } return s }
func (pac *Package) newStructNamer(t *gcc.Struct) Struct { return Struct{ exported: exported{ cName: t.CName(), file: t.File(), }, Conv: Value{namer{ goName: pac.globalName(t), cgoName: "C." + t.CName(), }}, } }
func (pac *Package) newStruct(t *gcc.Struct) Struct { s := pac.newStructNamer(t) s.Fields = pac.newStructFields(t.Fields()) return s }