[Lldb-commits] [lldb] [lldb] Fix help syntax for add-dsym (target symbols add) (PR #98976)
Jonas Devlieghere via lldb-commits
lldb-commits at lists.llvm.org
Mon Jul 15 16:30:12 PDT 2024
https://github.com/JDevlieghere created https://github.com/llvm/llvm-project/pull/98976
The help output incorrectly states that this command takes a shared library name (<shlib-name>) while really it takes a path to a symbol file.
rdar://131777043
>From 6cc124159e40ca432eba328828c04a9f3d66f103 Mon Sep 17 00:00:00 2001
From: Jonas Devlieghere <jonas at devlieghere.com>
Date: Mon, 15 Jul 2024 16:29:15 -0700
Subject: [PATCH] [lldb] Fix help syntax for add-dsym (target symbols add)
The help output incorrectly states that this command takes a shared
library name (<shlib-name>) while really it takes a path to a symbol
file.
rdar://131777043
---
lldb/source/Commands/CommandObjectTarget.cpp | 2 +-
lldb/test/Shell/SymbolFile/add-dsym.test | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/lldb/source/Commands/CommandObjectTarget.cpp b/lldb/source/Commands/CommandObjectTarget.cpp
index 80181a9b3cb71..d594330934ad7 100644
--- a/lldb/source/Commands/CommandObjectTarget.cpp
+++ b/lldb/source/Commands/CommandObjectTarget.cpp
@@ -4252,7 +4252,7 @@ class CommandObjectTargetSymbolsAdd : public CommandObjectParsed {
m_option_group.Append(&m_current_stack_option, LLDB_OPT_SET_2,
LLDB_OPT_SET_2);
m_option_group.Finalize();
- AddSimpleArgumentList(eArgTypeShlibName);
+ AddSimpleArgumentList(eArgTypeFilename);
}
~CommandObjectTargetSymbolsAdd() override = default;
diff --git a/lldb/test/Shell/SymbolFile/add-dsym.test b/lldb/test/Shell/SymbolFile/add-dsym.test
index cdcba641957d1..52d1a1363feef 100644
--- a/lldb/test/Shell/SymbolFile/add-dsym.test
+++ b/lldb/test/Shell/SymbolFile/add-dsym.test
@@ -1,5 +1,8 @@
# REQUIRES: system-darwin
+# RUN: %lldb -o 'help add-dsym' | FileCheck %s --check-prefix=HELP
+# HELP: Syntax: add-dsym <cmd-options> <filename>
+
# RUN: yaml2obj %S/Inputs/a.yaml -o %t.out
# RUN: LLDB_APPLE_DSYMFORUUID_EXECUTABLE=%S/Inputs/dsymforuuid.sh %lldb %t.out -o 'add-dsym -u 41945CA4-5D9D-3CDE-82B4-37E4C09750B5' 2>&1 | FileCheck %s
# CHECK: UUID information was not found
More information about the lldb-commits
mailing list