so if I have like 50 attributes then pointer is preferable then How big is big? I took from https://github.com/golang/go/wiki/CodeReviewComments for receiver, is this applicable for this too?
Assume it's equivalent to passing all its elements as arguments to the > method. If that feels too large, it's also too large for the receiver. > On Friday, 20 October 2017 12:25:27 UTC+7, Feby Tanzil wrote: > > Hi, > > I got vague answers in the internet over this. > Which is better & preferable in Go? > > type T struct { > // some attributes > ... > } > > func a() []T { > > } > > func b() []*T { > > } > > > > Thanks > -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.