mirror of
https://github.com/RPCSX/llvm.git
synced 2024-11-23 19:59:57 +00:00
[Bash-autocompletion] Show flags which has HelpText or GroupID
Summary: Otherwise internal flags will be also completed. Differential Revision: https://reviews.llvm.org/D34930 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@307116 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
3f4f926b6a
commit
7a41a9b0dc
@ -228,7 +228,7 @@ OptTable::suggestValueCompletions(StringRef Option, StringRef Arg) const {
|
||||
std::vector<std::string> OptTable::findByPrefix(StringRef Cur) const {
|
||||
std::vector<std::string> Ret;
|
||||
for (const Info &In : OptionInfos.slice(FirstSearchableIndex)) {
|
||||
if (!In.Prefixes)
|
||||
if (!In.Prefixes || (!In.HelpText && !In.GroupID))
|
||||
continue;
|
||||
for (int I = 0; In.Prefixes[I]; I++) {
|
||||
std::string S = std::string(In.Prefixes[I]) + std::string(In.Name);
|
||||
|
Loading…
Reference in New Issue
Block a user