In clang-format, what do the penalties do?
问题 The clang-format sytle options documentation includes a number of options called PenaltyXXX. The documentation doesn't explain how these penalties should be used. Can you describe how to use these penalty values and what effect they achieve (perhaps with an example)? 回答1: When you have a line that's over the line length limit, clang-format will need to insert one or more breaks somewhere . You can think of penalties as a way of discouraging certain line-breaking behavior. For instance, say