[cfe-commits] [PATCH] Initial version of formatting library
Dmitri Gribenko
gribozavr at gmail.com
Fri Nov 16 11:55:09 PST 2012
About the UnwrappedLine concept:
> changing the formatting within an unwrapped line does not affect any other unwrapped lines
This seems logical to me. From your patch I see how it works in case where we have declarations, statements and expression statements. But what if we have statements within an expression (for example, a body within the lambda), how is this idea going to work in practice? Could you please show unwrapped lines for the following example (split into multiple lines just for readability):
for_each(begin(l), end(l),
[&even_counter] (int n) {
if (n%2) cout << "odd" << endl; else cout << "even" << endl;
});
http://llvm-reviews.chandlerc.com/D80
More information about the cfe-commits
mailing list