I'm using astyle which is great for applying standard style to existing code. However I've noticed that when it comes across this:
ostringstream myStream;
myStream << 1
<< 2;
it reformats to this:
ostringstream myStream;
myStream << 1
<< 2;
Here's my options file: (version 1.23)
--indent=spaces --brackets=break --indent-switches --indent-namespaces --min-conditional-indent=4 --break-closing-brackets --pad-paren-in --unpad-paren --convert-tabs
Is there any way to make it line up the "<<" on the next line?
Edit:
I also tried version 1.22 with the following file (test.cpp):
void main()
{
ostringstream myStream;
myStream << 1
<< 2;
}
with the following options (format.txt):
--indent=spaces
--brackets=break-closing
--indent-switches
--indent-namespaces
--min-conditional-indent=4
--pad=paren-in
--unpad=paren
--convert-tabs
and the following command line:
astyle --options=format.txt test.cpp
which produced this:
void main()
{
ostringstream myStream;
myStream << 1
<< 2;
}