Comment Comment by Rubberducky1324 clang-tidy can often detect these. If the body of the function doesn't modify the value, for example.But it needs to be conservative of course, in general you can't do this. parent Rubberducky1324 1 year ago
But it needs to be conservative of course, in general you can't do this.