Skip to content

Commit

Permalink
Added SmallMap::operator==
Browse files Browse the repository at this point in the history
  • Loading branch information
vovagorodok committed Aug 10, 2024
1 parent eeff607 commit 6f1bbeb
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion library.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ArrayUtils",
"version": "1.2.1",
"version": "1.2.2",
"description": "Helps to create complex arrays and maps as arrays of pairs",
"keywords": "array, map, pair",
"repository":
Expand Down
2 changes: 1 addition & 1 deletion library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=vovagorodok_ArrayUtils
version=1.2.1
version=1.2.2
author=vovagorodok
maintainer=vovagorodok <[email protected]>
sentence=Helps to create complex arrays and maps as arrays of pairs
Expand Down
3 changes: 3 additions & 0 deletions src/SmallMap.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@ class SmallMap
return search->first;
return std::nullopt;
}
bool operator==(const SmallMap<Key, Value, N>& other) const {
return _arr == other._arr;
}

private:
std::array<std::pair<Key, Value>, N> _arr;
Expand Down

0 comments on commit 6f1bbeb

Please sign in to comment.