Closed mmghannam closed 1 week ago
@Nudelmeister turns out it was easy to do the change 😄 I would really appreciate a review here if you have the time :)
Update: there's a memory leak not sure why yet.
2nd Update: Fixed, was most probably because of thread unsafe counting of scip ptr references.
3rd Update: Was a false positive apparently :/
Attention: Patch coverage is 95.65217%
with 1 lines
in your changes are missing coverage. Please review.
Project coverage is 76.13%. Comparing base (
b44bc33
) to head (58fc879
).:exclamation: Current head 58fc879 differs from pull request most recent head 3d5df58. Consider uploading reports for the commit 3d5df58 to get more accurate results
Files | Patch % | Lines |
---|---|---|
src/solution.rs | 90.91% | 1 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
This seems fine, though I thought of wrapping the whole ScipPtr struct in an Arc. I can take a closer look tomorrow.
You could use a AtomicUsize
instead of RwLock<usize>
, but looking at how Arc
is implemented it's more complicated than I thought.
Other than the general uneasiness of the large amounts of unsafe (I guess you can't really do anything about that), I'm happy with this fix.
Thanks for the quick response.
You could use a
AtomicUsize
instead ofRwLock<usize>
, but looking at howArc
is implemented it's more complicated than I thought. Other than the general uneasiness of the large amounts of unsafe (I guess you can't really do anything about that), I'm happy with this fix.
Thanks for the suggestion, I changed it :) There's still a memory leak, I will merge this once I figure out why and fix it.
Thanks for the quick response.
Thank you too for the quick review :)
Fixes #138