3 ms·
This is actually a very nice explanation! I also enjoyed the linked article about the 5 value types: https://blog.knatten.org/2018/03/09/lvalues-rvalues-glvalu
by spacechild1 1y ago
This is actually a very nice explanation!
I also enjoyed the linked article about the 5 value types: https://blog.knatten.org/2018/03/09/lvalues-rvalues-glvalues-prvalues-xvalues-help/ https://blog.knatten.org/2018/03/09/lvalues-rvalues-glvalues.... For some reason I never bothered to look up these terms as they sounded so obscure. Turns out the taxonomy is pretty clear and it's just a refinement of the existing two value types (lvalues and rvalues).
EDIT: I do think the naming is rather confusing and inconsistent, though.
- dilawar 1y agoLooks like a cultural problem in C++ land. I liked the article and it is very nicely written. But I am sure I am not gonna remember it after a week. RAII is even worse! Can't they have better descriptive names?
- cordenr 1y agoRAII is so before 2020s! Now it's SBRM* *Scoped bound resource management... which I had to look up because I never remember it!
- spacechild1 1y agoSorry for being pedantic and possibly ruining the joke: SBRM is actually a subset of RAII because it only applies to automatic variables (hence "scope bound").
- spacechild1 1y agoI think RAII is so catchy and ubiquitous that people don't actually think or care about the meaning of the acronym. I never had a problem remembering it. I still struggle with CRTP and CTAD, though.