Closed ToMe25 closed 4 months ago
@bors r+
:pushpin: Commit fc448cf3f4f0927078f74974bac75bca0e874946 has been approved by Amanieu
It is now in the queue for this repository.
:hourglass: Testing commit fc448cf3f4f0927078f74974bac75bca0e874946 with merge 62dd52194e4148ca91aab1a0687904719e51508c...
:broken_heart: Test failed - checks-actions
That error seems to be a Dead Code error which I'm pretty sure this PR couldn't have caused, is there anything I can/should do about this?
Just add #[cfg(feature = "raw")]
to these types. The CI failure is probably due to lint changes in nightly rustc.
Ok, I'll do that tomorrow.
Hooray that actually fixed CI.
@bors r+
:pushpin: Commit 4b6e11d3a5753521b2f6543a25da1366ac8809b6 has been approved by Amanieu
It is now in the queue for this repository.
:hourglass: Testing commit 4b6e11d3a5753521b2f6543a25da1366ac8809b6 with merge e25e6bb02e4fe4d58835f525d60f86091f41d50f...
:sunny: Test successful - checks-actions Approved by: Amanieu Pushing e25e6bb02e4fe4d58835f525d60f86091f41d50f to master...
By using the
Intersection
iterator inHashSet::is_Disjoint
its performance can be significantly improved in some cases.This is because
intersection()
always uses the shorter set as its iterator.It would also be possible to replicate this "Iterate over the smaller set and check in the larger set" logic in the is_disjoint method.
However in my benchmarks the approach I chose is faster than that.
This change only causes a significant improvement when called on the larger of two disjoint sets.
My benchmark results: