diff options
author | Med Ismail Bennani <ismail@bennani.ma> | 2024-08-08 12:55:10 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-08 12:55:10 -0700 |
commit | 8334d2bfd34e2666db173269525d17352afa7bac (patch) | |
tree | a855cd8bc307146c48f572ace41d1e38b0bcb1ef /lldb/source/Commands/CommandObjectCommands.cpp | |
parent | 6a482972e01bf347c8ac22fc90f96fa01cb4eec1 (diff) | |
download | llvm-8334d2bfd34e2666db173269525d17352afa7bac.zip llvm-8334d2bfd34e2666db173269525d17352afa7bac.tar.gz llvm-8334d2bfd34e2666db173269525d17352afa7bac.tar.bz2 |
[lldb/Interpreter] Fix ambiguous partial command resolution (#101934)
This patch is a follow-up to #97263 that fix ambigous abbreviated
command resolution.
When multiple commands are resolved, instead of failing to pick a
command to
run, this patch changes to resolution logic to check if there is a
single
alias match and if so, it will run the alias instead of the other
matches.
This has as a side-effect that we don't need to make aliases for every
substring of aliases to support abbrivated alias resolution.
Signed-off-by: Med Ismail Bennani <ismail@bennani.ma>
Diffstat (limited to 'lldb/source/Commands/CommandObjectCommands.cpp')
-rw-r--r-- | lldb/source/Commands/CommandObjectCommands.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/lldb/source/Commands/CommandObjectCommands.cpp b/lldb/source/Commands/CommandObjectCommands.cpp index c63445b..7c439f4 100644 --- a/lldb/source/Commands/CommandObjectCommands.cpp +++ b/lldb/source/Commands/CommandObjectCommands.cpp @@ -322,7 +322,13 @@ rather than using a positional placeholder:" (lldb) command alias bl3 breakpoint set -f %1 -l 3 - Always sets a breakpoint on line 3 of whatever file is indicated.)"); + Always sets a breakpoint on line 3 of whatever file is indicated. + +)" + + "If the alias abbreviation or the full alias command collides with another \ +existing command, the command resolver will prefer to use the alias over any \ +other command as far as there is only one alias command match."); CommandArgumentEntry arg1; CommandArgumentEntry arg2; |