Reduce penalty for splitting between ")" and ".".
').' is likely part of a builder pattern statement. This is based upon a patch developed by Nico Weber. Thank you! Before: int foo() { return llvm::StringSwitch<Reference::Kind>(name).StartsWith( ".eh_frame_hdr", ORDER_EH_FRAMEHDR).StartsWith( ".eh_frame", ORDER_EH_FRAME).StartsWith(".init", ORDER_INIT).StartsWith( ".fini", ORDER_FINI).StartsWith(".hash", ORDER_HASH).Default(ORDER_TEXT); } After: int foo() { return llvm::StringSwitch<Reference::Kind>(name) .StartsWith(".eh_frame_hdr", ORDER_EH_FRAMEHDR) .StartsWith(".eh_frame", ORDER_EH_FRAME) .StartsWith(".init", ORDER_INIT).StartsWith(".fini", ORDER_FINI) .StartsWith(".hash", ORDER_HASH).Default(ORDER_TEXT); } Probably not ideal, but makes many cases much more readable. The changes to overriding-ftemplate-comments.cpp don't seem better or worse. We should address those soon. llvm-svn: 172804
Loading
Please register or sign in to comment