[PATCH] D70620: [CommandLine] Add callbacks to Options

Fangrui Song via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 4 10:00:49 PST 2019


MaskRay added inline comments.


================
Comment at: llvm/include/llvm/Support/CommandLine.h:477
+
+  cb(std::function<void(const Ty &)> CB) : CB(CB) {}
+
----------------
Is the constructor needed? Can the call site below (`cb<Ty>(CB);`) just use aggregate initialization?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D70620/new/

https://reviews.llvm.org/D70620





More information about the llvm-commits mailing list