Skip to content

Releases: elliotchance/pie

v1.19.0

08 May 06:27
aa52e36
Compare
Choose a tag to compare
added: Diff (#112)

Diff returns the elements that need to be added or removed from the first slice to have the same elements in the second slice.

The order of elements is not taken into consideration, so the slices are treated sets that allow duplicate items.

The added and removed returned may be blank respectively or contain up to as many elements that exist in the largest slice.

Fixes #75

v1.18.0

07 May 23:21
Compare
Choose a tag to compare
added: SortStableUsing and SortUsing (#103)

SortStableUsing works similar to sort.SliceStable. However, unlike sort.SliceStable the slice returned will be reallocated as to not modify the input slice.

SortUsing works similar to sort.Slice. However, unlike sort.Slice the slice returned will be reallocated as to not modify the input slice.

Fixes #98

v1.17.1

07 May 23:18
Compare
Choose a tag to compare
docs: Unique is O(n) (#102)

Fixes #92

v1.17.0

07 May 22:22
Compare
Choose a tag to compare
added: Reduce (#106)

Reduce continually applies the provided function over the slice. Reducing the elements to a single value.

Returns a zero value of ElementType if there are no elements in the slice. It will panic if the reducer is nil and the slice has more than one element (required to invoke reduce).

Otherwise returns a ​result of applying reducer from left to right.

Fixes #87

v1.16.0

07 May 00:33
Compare
Choose a tag to compare
added: Product (#109)

Product is the product of all of the elements.

Fixes #69

v1.15.0

06 May 23:16
Compare
Choose a tag to compare
Intersect (#94)

Intersect returns items that exist in all lists. It returns slice without any duplicates. If zero slice arguments are provided, then nil is returned.

Fixes #71
Updates #72

v1.14.0

05 May 22:32
Compare
Choose a tag to compare
Rename Select, Unselect and Transform (#89)

See the ​full discussion in #86.

Fixes #86

v1.13.1

05 May 22:28
Compare
Choose a tag to compare
Remove circular dependency on `pie/strings_pie.go` (#100)

The file main.go, used to build the pie command and in turn to generate pie/*_pie.go files, references pie/strings_pie.go function Contains. Because there is only one use and the use case is simple, removing the circular dependency allows the generate/re-generation of pie/*_pie.go functions to be generated without already existing. This also covers the edge case of generating pie/strings_pie.go without the Contains function.

Fixes #99

v1.13.0

05 May 09:46
Compare
Choose a tag to compare
Send func (#88)

Fixes #84

v1.12.1

04 May 01:03
Compare
Choose a tag to compare
Update gitignore to include common vim files (#90)