Make the modernize-loop-convert's const-detection smarter.
Now, it detects that several kinds of usages are can't modify the elements. Examples:
-When an usage is a call to a const member function or operator of the element.
-If the element is used as an argument to a function or constructor that takes a const-reference or a value.
-LValue to RValue conversion, if the element is a fundamental type (which allows the use of most of the builtin operators).
Subscribers: cfe-commits, alexfh
Differential Revision: http://reviews.llvm.org/D14198