Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add conditional conformances of CircularBuffer to Equatable and Hashable
Motivation: In general, Swift collections and sequences automatically conforms to Equatable and Hashable when their Element conforms to Equatable and Hashhable, respectively. This wasn't the case of CircularBuffer, which was unintuitive and could cause useless boilerplate code. Modifications: CircularBuffer has been extended so that it conforms to Equatable when its Element is Equatable, and to Hashable when its element is Hashable. Corresponding test cases have been added. Result: Appropriate conditional conformances of CircularBuffer to Equatable and Hashable
- Loading branch information
1 parent
8c6c83c
commit fee7195
Showing
3 changed files
with
75 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters