Details
-
Bug
-
Resolution: Incomplete
-
P3: Somewhat important
-
None
-
Qt Creator 4.7.0, Qt Creator 4.8.0-beta2
-
None
Description
I regularly use lambdas inside std-Algorithms. Since the lambda is a parameter of the std-call, I manually indent the opening and closing bracket accordingly:
std::transform(container.begin(), container.end(), std::back_inserter(target), [](const QString& string) { return string.count(); });
Often, the editor later changes the last line, without any action on my side, and without my consent:
std::transform(container.begin(), container.end(), std::back_inserter(target), [](const QString& string) { return string.count(); });
The line is also marked "red" as unsaved. Since I wrote the whole block in one go and then saved it, this clearly indicates that the change was made at a later time by the editor.
I suspect that this happens when I do a refactoring action that creates a new method in the same class.
Note: I never used the tool to correct indentation (Ctrl-I)