Details
-
Bug
-
Resolution: Fixed
-
P3: Somewhat important
-
Qt Creator 3.0.0, Qt Creator 3.1.0-beta
-
QT Creator 3.0.0, MinGW 4.8, Windows 8
Description
"Correct indentation" doesn't work correctly if you combine brace initialization and the conditional assignment operator.
Minimal example:
Copy and paste the text below into the QT Creator 3.0.0 editor and try to correct the indentation (e.g. via CTRL-I).
Input:
int main() { int i = 1; int j{i?5:10}; return 0; }
Expected output:
int main() { int i = 1; int j{i?5:10}; return 0; }
Output:
int main() { int i = 1; int j{i?5:10}; return 0; }
Attachments
Issue Links
- is duplicated by
-
QTCREATORBUG-15775 Incorrect indent after return with conditional using an array operator
- Closed
-
QTCREATORBUG-17548 Wrong indentation after conditional operator in brace init list
- Closed
-
QTCREATORBUG-10957 The use of conditional operator inside the uniform initialization breaks the auto indentation
- Closed
- replaces
-
QTCREATORBUG-15715 operator ? in member initializer list confuses formatter
- Closed