You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This syntax is useful when unioning multiple slices without separating the first one from the rest:
// This is easier:
pie.Strings{}.Union(zeroOrMoreSlices...)
// Than handling the nil case:iflen(zeroOrMoreSlices) ==0 {
returnnil;
}
returnzeroOrMoreSlices[0].Extend(zeroOrMoreSlices[1:]...)
The text was updated successfully, but these errors were encountered:
Unlike Append() and Extend(), Union() always considered the slice empty:
This syntax is useful when unioning multiple slices without separating the first one from the rest:
The text was updated successfully, but these errors were encountered: