Closed shepmaster closed 4 years ago
Good point. I'll try to squeeze it into the documentation while not overloading the reader with too much information.
It's due to technical limitations ‒ such pointers are fat and can't be fed into AtomicPtr
.
It is actually possible to do so using triomphe::ThinArc
with feature arc-swap
enabled.
Thanks for finding that one out. It's still a bit of cheating that can't be used everywhere (I think this works for variable-sized slices, but not for trait objects, am I right?), but worth mentioning in the relevant chapter ‒ I've updated it. I'll piggy-back it with the next release.
I think this works for variable-sized slices, but not for trait objects, am I right?
Yes that’s correct.