--style=bsd
# BSD style uses broken braces. (-A1)
# e.g.
# int Foo(bool isBar)
# {
#     if (isBar)
#     {
#         bar();
#         return 1;
#     }
#     else
#         return 0;
# }

--indent=spaces=4
# Indent using 4 spaces per indent. (-s4) 

--attach-closing-while
# Attach the closing while of a do-while statement to the closing brace. (-xV)
# e.g.
# do
# {
#     bar();
#     ++x;
# }
# while x == 1;
# becomes:
# do
# {
#     bar();
#     ++x;
# } while x == 1;

--indent-switches
# Indent switch blocks so that the case statements are indented in the switch block. (-S)
# e.g.
# switch (foo)
# {
# case 1:
#     a += 1;
#     break;
# 
# case 2:
# {
#     a += 2;
#     break;
# }
# }
# becomes:
# switch (foo)
# {
#     case 1:
#         a += 1;
#         break;
# 
#     case 2:
#     {
#         a += 2;
#         break;
#     }
# }

--indent-preproc-block
# Indent preprocessor blocks at brace level zero and immediately within a namespace. (-xW)
# e.g.
# #ifdef _WIN32
# #include <windows.h>
# #ifndef NO_EXPORT
# #define EXPORT
# #endif
# #endif
# becomes:
# #ifdef _WIN32
#     #include <windows.h>
#     #ifndef NO_EXPORT
#         #define EXPORT
#     #endif
# #endif

--indent-preproc-define
# Indent multi-line preprocessor definitions ending with a backslash. (-w)
# e.g.
# #define Is_Bar(arg,a,b) \
# (Is_Foo((arg), (a)) \
# || Is_Foo((arg), (b)))
# becomes:
# #define Is_Bar(arg,a,b) \
#     (Is_Foo((arg), (a)) \
#      || Is_Foo((arg), (b)))

--indent-col1-comments
# Indent C++ comments beginning in column one. (-Y)
# e.g.
# void Foo()
# {
# // comment
#     if (isFoo)
#         bar();
# }
# becomes:
# void Foo()
# {
#     // comment
#     if (isFoo)
#         bar();
# }

--max-continuation-indent=120
# Set the  maximum of 120 spaces to indent a continuation line. (-M120)
# e.g.
# fooArray[] = { red,
#          green,
#          blue };
# fooFunction(barArg1,
#          barArg2,
#          barArg3);
# becomes (with larger value):
# fooArray[] = { red,
#                green,
#                blue };
# fooFunction(barArg1,
#             barArg2,
#             barArg3);

--break-blocks
# Pad empty lines around header blocks. (-f)
# e.g.
# isFoo = true;
# if (isFoo) {
#     bar();
# } else {
#     anotherBar();
# }
# isBar = false;
# becomes:
# isFoo = true;
# 
# if (isFoo) {
#     bar();
# } else {
#     anotherBar();
# }
# 
# isBar = false;

--pad-oper
# Insert space padding around operators. (-p)
# e.g.
# if (foo==2)
#     a=bar((b-c)*a,d--);
# becomes:
# if (foo == 2)
#     a = bar((b - c) * a, d--);

--pad-comma
# Insert space padding after commas. (-xg)
# e.g.
# if (isFoo(a,b))
#     bar(a,b);
# becomes:
# if (isFoo(a, b))
#     bar(a, b);

--pad-header
# Insert space padding between a header and the following paren. (-H)
# e.g.
# if(isFoo((a+2), b))
#     bar(a, b);
# becomes:
# if (isFoo((a+2), b))
#     bar(a, b);

--unpad-paren
# Remove extra space padding around parens on the inside and outside. (-U)
# e.g.
# if ( isFoo( ( a+2 ), b ) )
#     bar ( a, b );
# becomes (with no padding option requested):
# if(isFoo((a+2), b))
#     bar(a, b);

--align-pointer=name
# Attach a pointer or reference operator to variable name. (-k3)
# e.g.
# char* foo1;
# char & foo2;
# string ^s1;
# becomes (with align-pointer=name):
# char *foo1;
# char &foo2;
# string ^s1;

--align-reference=name
# This option will align references separate from pointers. (-W3)
# e.g.
# char& foo3;
# becomes (with align-reference=name):
# char &foo3;

--attach-return-type
--attach-return-type-decl
# Attach the return type to the function name.
# The two options are for the function definitions (-xf),
# and the function declarations or signatures (-xh).
# e.g.
# void
# Foo(bool isFoo);
# becomes:
# void Foo(bool isFoo);

--convert-tabs
# Converts tabs into spaces in the non-indentation part of the line. (-c)

--max-code-length=200
# Break a line if the code exceeds 200 characters. (-xC200)

--suffix=none
# Do not retain a backup of the original file. (-n)

--exclude=myretarget.c
--exclude=retarget.c
--exclude=semihosting.h
--exclude=Library/CMSIS
--exclude=ThirdParty 
# Specify a file or subdirectory to be excluded from processing.

--ignore-exclude-errors-x
# Allow processing to continue if there are errors in the exclude options. (-xi)

--lineend=windows
# Force use of the specified line end style. (-z1)
