Skip to content
Commit 8f7e7f73 authored by Alexander Kornienko's avatar Alexander Kornienko
Browse files

[clang-tidy] Add check misc-braces-around-statements.

This check looks for if statements and loops: for, range-for, while and
do-while, and verifies that the inside statements are inside braces '{}'.
If not, proposes to add braces around them.

Example:

  if (condition)
    action();

becomes

  if (condition) {
    action();
  }

This check ought to be used with the -format option, so that the braces be
well-formatted.


Patch by Marek Kurdej!

http://reviews.llvm.org/D5395

llvm-svn: 218898
parent 325111bc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment