Like with ForEachMacros, support user to provide additional macros that act like if statements.
This makes it possible to support KJ_IF_MAYBE from the cap'n'proto library:
https://github.com/capnproto/capnproto/blob/master/kjdoc/tour.md#maybes.
Differential D102730
[clang-format] Support custom If macros • vlovich on May 18 2021, 3:29 PM. Authored by
Details Like with ForEachMacros, support user to provide additional macros that act like if statements. This makes it possible to support KJ_IF_MAYBE from the cap'n'proto library:
Diff Detail Event Timeline
Comment Actions Looks good, but please add a test with the else IF and just else case. Also for me it would be ok to add your KJ_IF_MAYBE to the default configuration. But I have no experience on that.
Comment Actions Review response:
Comment Actions Fixed missing _ after the hyperlink to the KJ link in the Style options documentation. I'm assuming that's required formatting for hyperlinks by what renders the markdown.
Comment Actions Review response. Updated the options I changed via the dump_format_style.py script but didn't ingest all the other changes it generated.
Comment Actions Thanks for working on this! Concerning the lexer part, I wouldn't do anything cleaner.
Comment Actions Review response I've updated coverage for AllowShortIfStatementsOnASingleLine and |
stiled? did you mean styled?