diff options
Diffstat (limited to 'Completion/Unix/Command')
-rw-r--r-- | Completion/Unix/Command/_gcc | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Completion/Unix/Command/_gcc b/Completion/Unix/Command/_gcc index bbfbc2b9e..9ec09200e 100644 --- a/Completion/Unix/Command/_gcc +++ b/Completion/Unix/Command/_gcc @@ -13,6 +13,11 @@ if [[ "$service" = -value-* ]]; then args2=() fi else + # On some systems (macOS), cc/gcc/g++ are actually clang; treat them accordingly + [[ $service != clang* ]] && + _pick_variant clang=clang unix --version && + service=clang-$service + args2=( '*:input file:_files -g "*.([cCmisSoak]|cc|cpp|cxx|ii|k[ih])(-.)"' ) fi |