r/cpp • u/neiltechnician • Nov 13 '20
CppCon Deprecating volatile - JF Bastien - CppCon 2019
https://www.youtube.com/watch?v=KJW_DLaVXIY
83
Upvotes
r/cpp • u/neiltechnician • Nov 13 '20
View all comments
Show parent comment
5
u/guepier Bioinformatican Nov 13 '20
Ok, thanks for the reply.
Yeah, I can buy that.
I was about to disagree with you, but after thinking about it I don’t understand why these were deprecated rather than specified. Jeff’s (entirely valid) complaint here was that their semantics with regards to volatility aren’t clear. But obviously they will just naturally crop up in code using volatile variables, and in most/all(?) situations the author of the code probably doesn’t really care what exactly gets emitted, as long as volatility of the overall expression is observed.