I understand the behavior of const-qualified data types. I am curious, though, if there is any performance gain or loss from over- or under-zealousness of quali
In my (limited) experience, const CAN hurt the performance by quite a lot (surprise!) Namely, when working with container classes be careful what cont-ness does: for arrays it might simply force the compiler to create a copy of your container (e.g., an array) once a single element is accessed for reading only... This was a huge pain to locate in the code that I am working on.