A small example:
A slice got wraps the want-struct on each comma,
tests := []struct {
name string
want autogold.Value
}{
{name: "good", want: autogold.Want("good", []A{A{
A: valast.Addr("abc").(*string),
B: "def",
C: valast.Addr(false).(*bool),
D: valast.Addr(true).(*bool),
}})},
}
while a non-slice got does not wrap on every comma
tests := []struct {
name string
want autogold.Value
}{
{name: "good", want: autogold.Want("good", A{
A: valast.Addr("abc").(*string), B: "def", C: valast.Addr(false).(*bool),
D: valast.Addr(true).(*bool),
})},
}
. I think it would be nice for non-slice wants to also wrap them on every comma. I know this is a small thing, so may not be worth it. It may also be more compact to keep it the current way. But I'd love an option to have it both the same output style - the slice-way.
I hope this is something you want input about. I thought I mention it before it is in wider use and more difficult to change. :-)
A small example:
A slice got wraps the want-struct on each comma,
while a non-slice got does not wrap on every comma
. I think it would be nice for non-slice wants to also wrap them on every comma. I know this is a small thing, so may not be worth it. It may also be more compact to keep it the current way. But I'd love an option to have it both the same output style - the slice-way.
I hope this is something you want input about. I thought I mention it before it is in wider use and more difficult to change. :-)