[clang][cli] Unify boolean marshalling
authorJan Svoboda <jan_svoboda@apple.com>
Mon, 7 Dec 2020 13:22:23 +0000 (14:22 +0100)
committerJan Svoboda <jan_svoboda@apple.com>
Tue, 8 Dec 2020 12:47:30 +0000 (13:47 +0100)
commit083e035c47f6c73084ecf5ab7f41cddca19ce332
treee186d68ee45db40104afd5e5fe01e3da37f08b67
parent41d0666391131ddee451085c72ba6513872e7f6c
[clang][cli] Unify boolean marshalling

Use lambdas with captures to replace the redundant infrastructure for marshalling of two boolean flags that control the same keypath.

Reviewed By: dexonsmith

Differential Revision: https://reviews.llvm.org/D92773
clang/include/clang/Driver/Options.td
clang/lib/Frontend/CompilerInvocation.cpp
llvm/include/llvm/Option/OptParser.td
llvm/utils/TableGen/OptParserEmitter.cpp