CLion 中使用 clang-format

Posted 芥末的无奈

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了CLion 中使用 clang-format相关的知识,希望对你有一定的参考价值。

Clion 中开启 clang-format

Preferences -> Editor -> Code Style -> “Enable ClangFormat”

在保存时自动代码格式化

Preferences -> Tools -> Actions on Save -> Reformat code

以上是关于CLion 中使用 clang-format的主要内容,如果未能解决你的问题,请参考以下文章