Skip to content

Releases: elliotchance/orderedmap

v2.4.0

17 Aug 22:25
9767ae7
Compare
Choose a tag to compare
Implement Go 1.23 iterators (#41)

Those are the Go 1.23 iterator that can be used with `for ... range`:
https://go.dev/doc/go1.23#iterators.

v2.3.0

17 Aug 22:24
f5ea9d1
Compare
Choose a tag to compare
Add ReplaceKey (#37)

ReplaceKey replaces an existing key with a new key while preserving order of
the value. This function will return true if the operation was successful, or
false if 'originalKey' is not found OR 'newKey' already exists (which would be an overwrite).

v1.6.0

24 May 20:14
f5ea9d1
Compare
Choose a tag to compare
Add ReplaceKey (#37)

ReplaceKey replaces an existing key with a new key while preserving order of
the value. This function will return true if the operation was successful, or
false if 'originalKey' is not found OR 'newKey' already exists (which would be an overwrite).

v1.5.1

06 Nov 16:11
8a25936
Compare
Choose a tag to compare
update performance test times to avoid accidental factors (#34)

v1.5.0

07 Sep 14:10
1e43e19
Compare
Choose a tag to compare
Improve performances of v1 (#32)

Try to improve the performance of the ordered map without generics. Apply the same approach already used for V2 in commit b46f20e44cbd130f70390d9ae9f253d64f441dc4.

v2.2.0

04 Sep 18:48
b46f20e
Compare
Choose a tag to compare
Performance improvements (#30)

Notes:
- avoid allocating an Element when iterating using (*Element).Next() and (*Element).Prev()
- avoid allocating an Element when calling (*OrderedMap).Front() and (*OrderedMap).Back()
- avoid computing the length of the doubly linked list since it is not strictly needed

Advantages:
- no need of (*Element).list field: save both memory and assignations
- avoid comparisons in (*Element).Next() and (*Element).Prev(): save time
- allow implicit initialization: style
- avoid comparisons in (*list).Front() and (*list).Back(): save time
- keep almost the same execution time for (*list).Remove(), (*list).PushFront() and (*list).PushBack()

v2.1.1

04 Sep 18:34
32f08ce
Compare
Choose a tag to compare
ci: Test on pull request (#31)

We also need to run tests on external pull requests.

v2.1.0

03 Sep 17:28
ef17579
Compare
Choose a tag to compare
Require comparable interface instead of constraints.Ordered for map k…

…eys (#29)

v2.0.1

09 Apr 01:54
ebace64
Compare
Choose a tag to compare
Adding Github Actions (#27)

This replaces the flakey Travis CI for testing.

v2.0.0

09 Apr 01:37
da74303
Compare
Choose a tag to compare
Added support for generics (#26)

Generics (in Go 1.18) are an ideal case for this library. It is provided
through a new version v2. If you need to support Go 1.17 or below you can
continue to use v1.