On 3/26/2017 3:29 PM, deadalnix wrote:
Note that using const Class* in C++ is essentially useless. The class remains
mutable and the reference is local the the callee anyway, so it doesn't change
anything for the caller. Such a pattern is most likely indicative of a bug on
the C++ side, or at least of code that do not do what the author intend to.

Ironically, because C++ const is not transitive, most programmers use const in C++ as if it was transitive. This is most evident in templates where:

   const T

is used.

Reply via email to