sammccall accepted this revision. sammccall added inline comments. This revision is now accepted and ready to land.
================ Comment at: clang-tools-extra/clangd/CompileCommands.cpp:216 + for (auto *Input : ArgList.filtered(driver::options::OPT_INPUT)) { + // Driver name is also considered an input, don't strip that away. + if (Input->getIndex() == 0) ---------------- Is this because we're not meant to be parsing argv0? Maybe check that and fix that here if so, or leave a FIXME if we don't want to check now? ================ Comment at: clang-tools-extra/clangd/CompileCommands.cpp:226 + [&Cmd](unsigned Idx) { Cmd.erase(Cmd.begin() + Idx); }); + Cmd.insert(Cmd.end(), {"--", File.str()}); } ---------------- nit: Fairly sure this is copying File twice, init-lists are dumb. maybe just two push_backs instead? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D106639/new/ https://reviews.llvm.org/D106639 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits