llvm-project/lldb
Michael Buch 09f608fda5 [lldb][ClangExpression] Remove storage-class check when creating AsmLabel
This check was put in place to prevent static functions
from translation units outside the one that the current
expression is evaluated from taking precedence over functions
in the global namespace. However, this is really a different
bug. LLDB lumps functions from all CUs into a single AST and
ends up picking the file-static even when C++ context rules
wouldn't allow that to happen.

This patch removes the check so we apply the AsmLabel to all
FunctionDecls we create from DWARF if we have a linkage name
available. This makes the code-path easier to reason about and
allows calling static functions in contexts where we previously
would've chosen the wrong function.

We also flip the XFAILs in the API test to reflect what effect
this change has.

**Testing**

* Fixed API tests and added XFAIL

Differential Revision: https://reviews.llvm.org/D132231
2022-08-22 13:22:20 +01:00
..
bindings [lldb] Remove uses of six module (NFC) 2022-08-11 19:06:15 -07:00
cmake [clang][lldb][cmake] Use new `*_INSTALL_LIBDIR_BASENAME` CPP macro 2022-08-20 12:52:21 -04:00
docs [lldb] Fix formatting in python-reference.rst 2022-08-07 12:17:36 -06:00
examples [LLDB] Remove __future__ imports from examples 2022-08-15 09:04:25 +00:00
include/lldb [clang][lldb][cmake] Use new `*_INSTALL_LIBDIR_BASENAME` CPP macro 2022-08-20 12:52:21 -04:00
packages/Python/lldbsuite [lldb] Support specifying a custom libcxx for the API tests 2022-08-19 15:20:41 -07:00
resources
scripts
source [lldb][ClangExpression] Remove storage-class check when creating AsmLabel 2022-08-22 13:22:20 +01:00
test [lldb][ClangExpression] Remove storage-class check when creating AsmLabel 2022-08-22 13:22:20 +01:00
third_party/Python/module [lldb] Remove uses of six module (NFC) 2022-08-11 19:06:15 -07:00
tools [lldb] Use Optional::value instead of Optional::getValue (NFC) 2022-08-19 21:40:48 -07:00
unittests [clang][lldb][cmake] Use new `*_INSTALL_LIBDIR_BASENAME` CPP macro 2022-08-20 12:52:21 -04:00
utils [lldb] Refactor command option enum values (NFC) 2022-07-14 21:18:07 -07:00
.clang-format
.clang-tidy [LLDB] Applying clang-tidy modernize-use-override over LLDB 2022-04-22 13:29:47 -07:00
.gitignore
CMakeLists.txt lldb: Disable unittests if llvm_gtest target does not exist 2022-08-10 16:56:08 -07:00
CODE_OWNERS.txt [CODE OWNERS] Add wallace as code owner 2022-01-12 12:36:30 -08:00
LICENSE.TXT
use_lldb_suite_root.py