indent_braces_no_func

Whether to disable indenting function braces if indent_braces=true.

Possible values are true and false, default false.

Works only if indent_braces is true.

Examples

Config:

indent_braces = true
indent_braces_no_func = true

true

Before:

int main()
{
    int x = 10;
    int y = 20;

    // if with else
    if (x<y) {
        std::cout << "Also x is less than " << y << '\n';
    }
    else {
        std::cout << "Also x is more (or equal) than " << y << '\n';
    }

    return 0;
}

code after:

int main()
{
    int x = 10;
    int y = 20;

    // if with else
    if (x<y) {
        std::cout << "Also x is less than " << y << '\n';
        }
    else {
        std::cout << "Also x is more (or equal) than " << y << '\n';
        }

    return 0;
}

Note the "main" braces were not indented.

See also