Details
-
Type:
Bug
-
Status: Closed
-
Priority:
P2: Important
-
Resolution: Done
-
Affects Version/s: Qt Creator 4.9.0-rc1
-
Fix Version/s: Qt Creator 4.9.0
-
Component/s: C/C++/Obj-C++ Support
-
Labels:None
-
Environment:Gentoo Linux AMD64. Creator installed using the official Qt installer.
-
Platform/s:
-
Commits:01a528c77a3aee7cdd264f9f71d9b2d30a9c775a (qt-creator/qt-creator/4.9)
Description
When using the ClangFormat plugin, the editor will sometimes wrongly indent the current line when typing "(", "<" or ">". For example, when you have this:
int foo() { // Blah. if }
and the text cursor is at the "if", when you type the "(", the code gets indented:
int foo() { // Blah. if ( }
The same happens with this code too:
int foo() { #ifdef FOO #endif if ( }
Angle brackets have the same issue. For example:
int foo() { bar(); if (baz }
As soon as you type ">", it gets indented:
int foo() { bar(); if (baz > }