CLion using clang-format, C++ initializer lists not formatting correctly

Viewed 140

I dont understand what's going on here. My initializer lists are all appearing on one line suddenly today.

In CLion, if I click on clang-format at the bottom of the screen while in a cpp file and then click edit clang file, it opens the clang-format file I copied into the project root, which does not have a BreakConstructorInitializersBeforeComma: false line in it. ctrl-f in that actual file yields zero results for that line.

However, if I select view clang format options instead of edit, it shows that line in it the list of options, and also says it is from "

# ClangFormatConfigureSource: 'clang-format-file:///home/cpisz/myproject/.clang-format'

which is the same file where that line does not exist!

file->settings->editor->code style shows that `settings may be overridden by ClangFormat, so the instruction to use the clang-format file is surely enabled.

If I run the formatter from the command line, instead of within the IDE, it formats correctly. Arg!

Where is that option coming from and how can I get rid of it?

0 Answers
Related