jonhoo / left-right

A lock-free, read-optimized, concurrency primitive.
Apache License 2.0
1.94k stars 94 forks source link

add WriteHandle::take #96

Closed pYtoner closed 3 years ago

pYtoner commented 3 years ago

There might be a less clear way to let the Drop know that it needs to do things differently but a bool is not much overhead.

I am not sure how the usage of drop second should be documented. But what I wrote should be a good start I think.


This change is Reviewable

codecov[bot] commented 3 years ago

Codecov Report

Merging #96 (174645c) into master (a8f42a8) will increase coverage by 3.24%. The diff coverage is 96.29%.

Impacted Files Coverage Δ
src/write.rs 87.70% <96.29%> (+1.45%) :arrow_up:
src/lib.rs 84.61% <0.00%> (+9.61%) :arrow_up:
pYtoner commented 3 years ago

Should the version of the crate be changed also?

pYtoner commented 3 years ago

That seems like a good approach. I'll do it today.

jonhoo commented 3 years ago

Oh, by the way, you don't need to open a new PR for each change. You can just push another commit to the branch you made the commit from :)

pYtoner commented 3 years ago

Oh that makes it much easier. Thanks for letting me know. My first time contributing so things are new and fun :)