I was rewatching parts of your livestream and realise that add with a return value was headache inducing.
Feel free to close this if it's offtopic. But i thought about rewriting the sequential ID generator in my project with atomics.
Currently I am using an actor for that.
Looking at this module I could use compare_exchange and retry on error but i dont feel like that would be a good use of atomics.
Are you planning to revisit add returning the new value in the future?
I was rewatching parts of your livestream and realise that
add
with a return value was headache inducing.Feel free to close this if it's offtopic. But i thought about rewriting the sequential ID generator in my project with atomics. Currently I am using an actor for that.
Looking at this module I could use
compare_exchange
and retry on error but i dont feel like that would be a good use of atomics.Are you planning to revisit
add
returning the new value in the future?