[PATCH] D34770: [Bash-autocompletion] Auto complete cc1 options if -cc1 is specified
Saleem Abdulrasool via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jul 3 14:33:41 PDT 2017
compnerd accepted this revision.
compnerd added inline comments.
This revision is now accepted and ready to land.
================
Comment at: clang/lib/Driver/Driver.cpp:1236
+ // We want to show cc1-only options only when clang is invoked as "clang -cc1".
+ // When clang is invoked as "clang -cc1", we add "#" to ther beginning of an --autocomplete
+ // option so that the clang driver can distinguish whether it is requested to show cc1-only options or not.
----------------
Typo: `ther` -> `the`.
================
Comment at: clang/utils/bash-autocomplete.sh:16
+ if [[ "${COMP_WORDS[1]}" == "-cc1" || "$w1" == "-Xclang" ]]; then
+ arg="#"
+ fi
----------------
`prefix` may be a better term?
https://reviews.llvm.org/D34770
More information about the cfe-commits
mailing list