[Lldb-commits] [lldb] 8b280df - Rough guess at fixing lldb tests to handle Clang defaulting to DWARFv5

2022-01-23 Thread David Blaikie via lldb-commits

Author: David Blaikie
Date: 2022-01-23T21:24:25-08:00
New Revision: 8b280df504b97a13d06a929fbc85348903456fdd

URL: 
https://github.com/llvm/llvm-project/commit/8b280df504b97a13d06a929fbc85348903456fdd
DIFF: 
https://github.com/llvm/llvm-project/commit/8b280df504b97a13d06a929fbc85348903456fdd.diff

LOG: Rough guess at fixing lldb tests to handle Clang defaulting to DWARFv5

Added: 


Modified: 

lldb/test/API/functionalities/param_entry_vals/basic_entry_values/TestBasicEntryValues.py

lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py
lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-dwo-cross-reference.cpp

Removed: 




diff  --git 
a/lldb/test/API/functionalities/param_entry_vals/basic_entry_values/TestBasicEntryValues.py
 
b/lldb/test/API/functionalities/param_entry_vals/basic_entry_values/TestBasicEntryValues.py
index 4b9a814764158..f4ae1fc015569 100644
--- 
a/lldb/test/API/functionalities/param_entry_vals/basic_entry_values/TestBasicEntryValues.py
+++ 
b/lldb/test/API/functionalities/param_entry_vals/basic_entry_values/TestBasicEntryValues.py
@@ -15,4 +15,4 @@
 lldbinline.MakeInlineTest(__file__, globals(),
 decorators=decorators+[skipIf(debug_info="dsym")],
 name="BasicEntryValues_GNU",
-build_dict=dict(CXXFLAGS_EXTRAS="-O2 -ggdb"))
+build_dict=dict(CXXFLAGS_EXTRAS="-O2 -ggdb -gdwarf-4"))

diff  --git 
a/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py
 
b/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py
index cbdf40e2416f7..19aad2ab1ec32 100644
--- 
a/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py
+++ 
b/lldb/test/API/functionalities/tail_call_frames/unambiguous_sequence/TestUnambiguousTailCalls.py
@@ -7,5 +7,5 @@
 lldbinline.MakeInlineTest(__file__, globals(), name="UnambiguousTailCalls_V5",
 build_dict=dict(CFLAGS_EXTRAS="-O2 -glldb"), decorators=decor)
 lldbinline.MakeInlineTest(__file__, globals(), name="UnambiguousTailCalls_GNU",
-build_dict=dict(CFLAGS_EXTRAS="-O2 -ggdb"),
+build_dict=dict(CFLAGS_EXTRAS="-O2 -ggdb -gdwarf-4"),
 decorators=decor+[decorators.skipIf(debug_info="dsym")])

diff  --git 
a/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-dwo-cross-reference.cpp 
b/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-dwo-cross-reference.cpp
index 29adff62cd1ee..0e29cb3e7f16e 100644
--- a/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-dwo-cross-reference.cpp
+++ b/lldb/test/Shell/SymbolFile/DWARF/x86/debug-types-dwo-cross-reference.cpp
@@ -7,8 +7,8 @@
 // RUN:   -fdebug-types-section -gsplit-dwarf -c -o %t1.o -DONE
 // RUN: %clang %s -target x86_64-pc-linux -fno-standalone-debug -g \
 // RUN:   -fdebug-types-section -gsplit-dwarf -c -o %t2.o -DTWO
-// RUN: llvm-dwarfdump %t1.dwo -debug-types | FileCheck --check-prefix=ONEUNIT 
%s
-// RUN: llvm-dwarfdump %t2.dwo -debug-types | FileCheck --check-prefix=ONEUNIT 
%s
+// RUN: llvm-dwarfdump %t1.dwo -debug-types -debug-info | FileCheck 
--check-prefix=ONEUNIT %s
+// RUN: llvm-dwarfdump %t2.dwo -debug-types -debug-info | FileCheck 
--check-prefix=ONEUNIT %s
 // RUN: ld.lld %t1.o %t2.o -o %t
 // RUN: %lldb %t -o "target var a b **b.a" -b | FileCheck %s
 



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [PATCH] D117299: [lldb] Ignore non-address bits in "memory find" arguments

2022-01-23 Thread Muhammad Omair Javaid via Phabricator via lldb-commits
omjavaid accepted this revision.
omjavaid added inline comments.
This revision is now accepted and ready to land.



Comment at: 
lldb/test/API/linux/aarch64/tagged_memory_access/TestAArch64LinuxTaggedMemoryAccess.py:83
+# Then that the location found does not display the tag bits.
+self.assertNotRegexpMatches(out, "data found at location: 
0x(34|56)[0-9A-Fa-f]+")

DavidSpickett wrote:
> omjavaid wrote:
> > so I am thinking do we actually need to omit tags from location address. 
> > Internally we want LLDB to ignore tags thats fine but user must be seeing 
> > the tagged address of buf so why omit tags in output of memory find?
> > 
> TLDR: The logic here is that the tag (or more generally non-address) bits of 
> the pointer are a property of the pointer, not the memory pointed to.
> 
> More detail, since I've thought about this a lot. Please challenge if it 
> doesn't make sense.
> 
> You could argue that you're showing the user a "view" of memory through that 
> pointer. My problem there is that pointer auth and memory tagging break that 
> argument because you cannot assume they stay the same as the memory location 
> increments. Since you can't just assume that the signature for `ptr` and 
> `ptr+16` would be the same, or the memory tag for those locations would be 
> the same.
> 
> The only minor benefit there is the user can copy a tagged pointer to a later 
> location, but those tags may not actually let the program access the memory. 
> (though the debugger can always but it didn't need tags to do that in any 
> case)
> 
> This is what the full output looks like. If you wanted to display the tags in 
> the output which tag would you use? Well, simple choice is the start address 
> tag. However, it's really an arbitrary choice that I think doesn't help much.
> 
> ```
> (lldb) p ptr1
> (char *) $2 = 0x34411029 ""
> (lldb) p ptr2
> (char *) $3 = 0x56411029 ""
> (lldb) memory find -s '?' ptr2 ptr1+16
> data found at location: 0x411038
> 0x00411038: 3f 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ?...
> 0x00411048: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  
> ```
> 
> I agree there is an initial "why did my pointer get changed" reaction but 
> think I not showing non-address bits when showing actual memory is going to 
> be clearer in the long run. Granted this is mostly intuition, we don't have a 
> lot of user feedback about this at this stage.
> 
> Actual "memory tags" do have a tag that is attached to the memory location in 
> hardware, so you may want to show that. That's something I've been addressing 
> for "memory read" and will probably port that over to memory find as well. 
> It'll look something like:
> 
> ```
> (lldb) memory find -s '?' ptr2 ptr1+16
> data found at location: 0x411038
> 0x00411038: 3f 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  ?... 
> (tag: 0x1)
> 0x00411048: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00   
> (tag: 0x2)
> ```
> 
> Crucially here we're showing the real tag for each line, instead of assuming 
> that the one in the pointer can be applied to them all.
This actually makes me think if we should try adding a feature where we can 
enable/disable viewing off non-address-bits. The purpose is to allow average 
programmer debug their simple applications without any surprise of ever 
changing memory addresses. May be with time people will realize the non-address 
bits technology but for programmers switching back n forth between x64 and 
AArch64 may feel things happening differently unless they figure there is this 
non-address bits phenomenon. 

Anyways your patch does make sense for now unless we hear any user complaints.

Moreover additional tag information that you suggested above would be a good 
adon so +1 for that.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117299/new/

https://reviews.llvm.org/D117299

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [PATCH] D112824: [lldb][AArch64] Add MakeTaggedRanges to MemoryTagManager

2022-01-23 Thread Muhammad Omair Javaid via Phabricator via lldb-commits
omjavaid added inline comments.



Comment at: 
lldb/source/Plugins/Process/Utility/MemoryTagManagerAArch64MTE.cpp:177
+  // and exit early before it sees the overlap.
+  MemoryRegionInfos::const_iterator overlap = std::adjacent_find(
+  memory_regions.begin(), memory_regions.end(),

From implementation of Process::GetMemoryRegions It seems our regions vector 
will always be sorted and non-overlapping? Is it no so?

Process::GetMemoryRegions starts from addr zero and keeps fetching regions 
based on end_addr of previous range. So in all cases regions will be sorted. 


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D112824/new/

https://reviews.llvm.org/D112824

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [PATCH] D117928: [lldb] Disable tests for x86 that uses write command on XMM registers

2022-01-23 Thread Luís Ferreira via Phabricator via lldb-commits
ljmf00 added a comment.

In D117928#3263992 , @mgorny wrote:

> Thank you. Yes, please test on an older kernel, in case it's specifically a 
> kernel regression.

I can confirm regression on Linux LTS 5.10.93. Probably later and introduced by 
the patch I mentioned. I reported to the kernel bug tracker. See 
https://bugzilla.kernel.org/show_bug.cgi?id=215524 .

In D117928#3264795 , @labath wrote:

> If this is a problem with PTRACE_SETREGSET(NT_FPREGSET), then we might be 
> able to work around it by using PTRACE_POKEUSER instead. But it'd definitely 
> be good to confirm this, so that we can report the bug to kernel devs.

According to `ptrace` documentation `PTRACE_SETFPREGS` seems a better fit, 
although either this and `PTRACE_POKEUSER` disallow writing in some specific 
general-purpose registers, so we should only use this for FP/XMM registers? 
AFAIK BSD-based kernels implements `PT_SETXMMREGS` although I don't see any 
documentation on the Linux kernel side about this.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117928/new/

https://reviews.llvm.org/D117928

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] abb0ed4 - [Commands] Remove redundant member initialization (NFC)

2022-01-23 Thread Kazu Hirata via lldb-commits

Author: Kazu Hirata
Date: 2022-01-23T11:07:14-08:00
New Revision: abb0ed44957cb4ba1bc94d19202860f10369cea1

URL: 
https://github.com/llvm/llvm-project/commit/abb0ed44957cb4ba1bc94d19202860f10369cea1
DIFF: 
https://github.com/llvm/llvm-project/commit/abb0ed44957cb4ba1bc94d19202860f10369cea1.diff

LOG: [Commands] Remove redundant member initialization (NFC)

Identified with readability-redundant-member-init.

Added: 


Modified: 
lldb/source/Commands/CommandCompletions.cpp
lldb/source/Commands/CommandObjectBreakpoint.cpp
lldb/source/Commands/CommandObjectBreakpointCommand.cpp
lldb/source/Commands/CommandObjectCommands.cpp
lldb/source/Commands/CommandObjectDisassemble.cpp
lldb/source/Commands/CommandObjectExpression.cpp
lldb/source/Commands/CommandObjectFrame.cpp
lldb/source/Commands/CommandObjectHelp.cpp
lldb/source/Commands/CommandObjectHelp.h
lldb/source/Commands/CommandObjectLog.cpp
lldb/source/Commands/CommandObjectMemory.cpp
lldb/source/Commands/CommandObjectMemoryTag.cpp
lldb/source/Commands/CommandObjectPlatform.cpp
lldb/source/Commands/CommandObjectProcess.cpp
lldb/source/Commands/CommandObjectRegexCommand.cpp
lldb/source/Commands/CommandObjectRegister.cpp
lldb/source/Commands/CommandObjectReproducer.cpp
lldb/source/Commands/CommandObjectScript.h
lldb/source/Commands/CommandObjectSession.cpp
lldb/source/Commands/CommandObjectSettings.cpp
lldb/source/Commands/CommandObjectSource.cpp
lldb/source/Commands/CommandObjectStats.cpp
lldb/source/Commands/CommandObjectTarget.cpp
lldb/source/Commands/CommandObjectThread.cpp
lldb/source/Commands/CommandObjectTrace.cpp
lldb/source/Commands/CommandObjectType.cpp
lldb/source/Commands/CommandObjectWatchpoint.cpp
lldb/source/Commands/CommandObjectWatchpointCommand.cpp
lldb/source/Commands/CommandOptionsProcessLaunch.h

Removed: 




diff  --git a/lldb/source/Commands/CommandCompletions.cpp 
b/lldb/source/Commands/CommandCompletions.cpp
index ff825cce813ec..ae1ee1fdd30b8 100644
--- a/lldb/source/Commands/CommandCompletions.cpp
+++ b/lldb/source/Commands/CommandCompletions.cpp
@@ -129,7 +129,7 @@ class SourceFileCompleter : public Completer {
 public:
   SourceFileCompleter(CommandInterpreter &interpreter,
   CompletionRequest &request)
-  : Completer(interpreter, request), m_matching_files() {
+  : Completer(interpreter, request) {
 FileSpec partial_spec(m_request.GetCursorArgumentPrefix());
 m_file_name = partial_spec.GetFilename().GetCString();
 m_dir_name = partial_spec.GetDirectory().GetCString();

diff  --git a/lldb/source/Commands/CommandObjectBreakpoint.cpp 
b/lldb/source/Commands/CommandObjectBreakpoint.cpp
index 3f88a2fa63780..c4e55fdb3b9c0 100644
--- a/lldb/source/Commands/CommandObjectBreakpoint.cpp
+++ b/lldb/source/Commands/CommandObjectBreakpoint.cpp
@@ -49,7 +49,7 @@ static void AddBreakpointDescription(Stream *s, Breakpoint 
*bp,
 
 class lldb_private::BreakpointOptionGroup : public OptionGroup {
 public:
-  BreakpointOptionGroup() : OptionGroup(), m_bp_opts(false) {}
+  BreakpointOptionGroup() : m_bp_opts(false) {}
 
   ~BreakpointOptionGroup() override = default;
 
@@ -179,7 +179,7 @@ class lldb_private::BreakpointOptionGroup : public 
OptionGroup {
 
 class BreakpointDummyOptionGroup : public OptionGroup {
 public:
-  BreakpointDummyOptionGroup() : OptionGroup() {}
+  BreakpointDummyOptionGroup() {}
 
   ~BreakpointDummyOptionGroup() override = default;
 
@@ -234,8 +234,7 @@ class CommandObjectBreakpointSet : public 
CommandObjectParsed {
 interpreter, "breakpoint set",
 "Sets a breakpoint or set of breakpoints in the executable.",
 "breakpoint set "),
-m_bp_opts(), m_python_class_options("scripted breakpoint", true, 'P'),
-m_options() {
+m_python_class_options("scripted breakpoint", true, 'P') {
 // We're picking up all the normal options, commands and disable.
 m_all_options.Append(&m_python_class_options,
  LLDB_OPT_SET_1 | LLDB_OPT_SET_2, LLDB_OPT_SET_11);
@@ -253,9 +252,7 @@ class CommandObjectBreakpointSet : public 
CommandObjectParsed {
 
   class CommandOptions : public OptionGroup {
   public:
-CommandOptions()
-: OptionGroup(), m_condition(), m_filenames(), m_func_names(),
-  m_func_regexp(), m_source_text_regexp(), m_modules() {}
+CommandOptions() {}
 
 ~CommandOptions() override = default;
 
@@ -809,8 +806,7 @@ class CommandObjectBreakpointModify : public 
CommandObjectParsed {
 "created breakpoint.  "
 "With the exception of -e, -d and -i, passing an "
 "empty argument clears the modification.",
-nullptr),
-m_options() {
+nullptr) {

[Lldb-commits] [PATCH] D117928: [lldb] Disable tests for x86 that uses write command on XMM registers

2022-01-23 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment.

If this is a problem with PTRACE_SETREGSET(NT_FPREGSET), then we might be able 
to work around it by using PTRACE_POKEUSER instead. But it'd definitely be good 
to confirm this, so that we can report the bug to kernel devs.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D117928/new/

https://reviews.llvm.org/D117928

___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] 49d38b1 - Fix "not all control paths return a value" warning. NFC.

2022-01-23 Thread Simon Pilgrim via lldb-commits

Author: Simon Pilgrim
Date: 2022-01-23T15:14:10Z
New Revision: 49d38b1d618c02964af93068ee8e1ac753722104

URL: 
https://github.com/llvm/llvm-project/commit/49d38b1d618c02964af93068ee8e1ac753722104
DIFF: 
https://github.com/llvm/llvm-project/commit/49d38b1d618c02964af93068ee8e1ac753722104.diff

LOG: Fix "not all control paths return a value" warning. NFC.

Added: 


Modified: 
lldb/source/Plugins/Language/CPlusPlus/GenericBitset.cpp

Removed: 




diff  --git a/lldb/source/Plugins/Language/CPlusPlus/GenericBitset.cpp 
b/lldb/source/Plugins/Language/CPlusPlus/GenericBitset.cpp
index c8063915b178d..d1d844bb4ca41 100644
--- a/lldb/source/Plugins/Language/CPlusPlus/GenericBitset.cpp
+++ b/lldb/source/Plugins/Language/CPlusPlus/GenericBitset.cpp
@@ -72,6 +72,7 @@ ConstString 
GenericBitsetFrontEnd::GetDataContainerMemberName() {
   case StdLib::LibStdcpp:
 return ConstString("_M_w");
   }
+  llvm_unreachable("Unknown StdLib enum");
 }
 
 bool GenericBitsetFrontEnd::Update() {



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] d7aa402 - [lldb] PdbAstBuilder - use cast<> instead of dyn_cast<> to avoid dereference of nullptr

2022-01-23 Thread Simon Pilgrim via lldb-commits

Author: Simon Pilgrim
Date: 2022-01-23T15:11:08Z
New Revision: d7aa402b4b8a325a68c20d0300ac6bc664766be0

URL: 
https://github.com/llvm/llvm-project/commit/d7aa402b4b8a325a68c20d0300ac6bc664766be0
DIFF: 
https://github.com/llvm/llvm-project/commit/d7aa402b4b8a325a68c20d0300ac6bc664766be0.diff

LOG: [lldb] PdbAstBuilder - use cast<> instead of dyn_cast<> to avoid 
dereference of nullptr

The pointers are dereferenced immediately, so assert the cast is correct 
instead of returning nullptr

Added: 


Modified: 
lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp

Removed: 




diff  --git a/lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp 
b/lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp
index 9473befa6cc34..dc0969a0ce7c6 100644
--- a/lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp
+++ b/lldb/source/Plugins/SymbolFile/NativePDB/PdbAstBuilder.cpp
@@ -1081,7 +1081,7 @@ PdbAstBuilder::GetOrCreateFunctionDecl(PdbCompilandSymId 
func_id) {
 
   clang::FunctionDecl *function_decl = nullptr;
   if (parent->isRecord()) {
-clang::QualType parent_qt = llvm::dyn_cast(parent)
+clang::QualType parent_qt = llvm::cast(parent)
 ->getTypeForDecl()
 ->getCanonicalTypeInternal();
 lldb::opaque_compiler_type_t parent_opaque_ty =
@@ -1318,7 +1318,7 @@ void PdbAstBuilder::ParseAllNamespacesPlusChildrenOf(
 if (!context->isNamespace())
   continue;
 
-clang::NamespaceDecl *ns = llvm::dyn_cast(context);
+clang::NamespaceDecl *ns = llvm::cast(context);
 std::string actual_ns = ns->getQualifiedNameAsString();
 if (llvm::StringRef(actual_ns).startswith(*parent)) {
   clang::QualType qt = GetOrCreateType(tid);



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] d13847b - [lldb] TerminalState::Save - fix unused variable warning

2022-01-23 Thread Simon Pilgrim via lldb-commits

Author: Simon Pilgrim
Date: 2022-01-23T15:12:44Z
New Revision: d13847bbe5e632ec8f62abc81f74b9351a56d28c

URL: 
https://github.com/llvm/llvm-project/commit/d13847bbe5e632ec8f62abc81f74b9351a56d28c
DIFF: 
https://github.com/llvm/llvm-project/commit/d13847bbe5e632ec8f62abc81f74b9351a56d28c.diff

LOG: [lldb] TerminalState::Save - fix unused variable warning

Non-POSIX target builds don't use the file descriptor

Added: 


Modified: 
lldb/source/Host/common/Terminal.cpp

Removed: 




diff  --git a/lldb/source/Host/common/Terminal.cpp 
b/lldb/source/Host/common/Terminal.cpp
index 2a1c12e667bcf..831e9dff4eb18 100644
--- a/lldb/source/Host/common/Terminal.cpp
+++ b/lldb/source/Host/common/Terminal.cpp
@@ -417,8 +417,8 @@ bool TerminalState::Save(Terminal term, bool 
save_process_group) {
   Clear();
   m_tty = term;
   if (m_tty.IsATerminal()) {
-int fd = m_tty.GetFileDescriptor();
 #if LLDB_ENABLE_POSIX
+int fd = m_tty.GetFileDescriptor();
 m_tflags = ::fcntl(fd, F_GETFL, 0);
 #if LLDB_ENABLE_TERMIOS
 std::unique_ptr new_data{new Terminal::Data()};



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits


[Lldb-commits] [lldb] c934913 - [lldb] CxxModuleHandler - use cast<> instead of dyn_cast<> to avoid dereference of nullptr

2022-01-23 Thread Simon Pilgrim via lldb-commits

Author: Simon Pilgrim
Date: 2022-01-23T15:10:33Z
New Revision: c93491352cf3146559de7755283f0dd259392126

URL: 
https://github.com/llvm/llvm-project/commit/c93491352cf3146559de7755283f0dd259392126
DIFF: 
https://github.com/llvm/llvm-project/commit/c93491352cf3146559de7755283f0dd259392126.diff

LOG: [lldb] CxxModuleHandler - use cast<> instead of dyn_cast<> to avoid 
dereference of nullptr

The pointer is dereferenced immediately, so assert the cast is correct instead 
of returning nullptr

Added: 


Modified: 
lldb/source/Plugins/ExpressionParser/Clang/CxxModuleHandler.cpp

Removed: 




diff  --git a/lldb/source/Plugins/ExpressionParser/Clang/CxxModuleHandler.cpp 
b/lldb/source/Plugins/ExpressionParser/Clang/CxxModuleHandler.cpp
index 74dd04600b4be..fecffd1183f89 100644
--- a/lldb/source/Plugins/ExpressionParser/Clang/CxxModuleHandler.cpp
+++ b/lldb/source/Plugins/ExpressionParser/Clang/CxxModuleHandler.cpp
@@ -138,7 +138,7 @@ getEqualLocalDeclContext(Sema &sema, DeclContext 
*foreign_ctxt) {
 
   // We currently only support building namespaces.
   if (foreign_ctxt->isNamespace()) {
-NamedDecl *ns = llvm::dyn_cast(foreign_ctxt);
+NamedDecl *ns = llvm::cast(foreign_ctxt);
 llvm::StringRef ns_name = ns->getName();
 
 auto lookup_result = emulateLookupInCtxt(sema, ns_name, *parent);



___
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits