summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/lang/cpp
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Added support for -gmodule debugging when debug info is left in the ↵Tamas Berghammer2015-12-021-2/+2
| | | | | | | | | .o files on Darwin." The commit caused a test failure on the linux buildbot in TestDataFormatterSynthVal. llvm-svn: 254502
* Added support for -gmodule debugging when debug info is left in the .o files ↵Greg Clayton2015-12-021-2/+2
| | | | | | | | | | | | | | | | | | | | on Darwin. This is done by finding the types that are forward declarations that come from a module, and loading that module's debug info in a separate lldb_private::Module, and copying the type over into the current module using a ClangASTImporter object. ClangASTImporter objects are already used to copy types from on clang::ASTContext to another for expressions so the type copying code has been around for a while. A new FindTypes variant was added to SymbolVendor and SymbolFile: size_t SymbolVendor::FindTypes (const std::vector<CompilerContext> &context, bool append, TypeMap& types); size_t SymbolVendor::FindTypes (const std::vector<CompilerContext> &context, bool append, TypeMap& types); The CompilerContext is a way to represent the exact context of a type and pass it through an agnostic API boundary so that we can find that exact context elsewhere in another file. This was required here because we can have a module that has submodules, both of which have a "foo" type. I am not able to add tests for this yet as we currently don't build our C/C++/ObjC binaries with the clang binary that we build. There are some driver issues where it can't find the header files for the C and C++ standard library which makes compiling these tests hard. We can't also guarantee that if we are building with clang that it supporst the exact format of -gmodule debugging that we are trying to test. We have had other versions of clang that had a different implementation of -gmodule debugging that we are no longer supporting, so we can't enable tests if we are building with clang without compiling something and looking at the structure of the DWARF that was generated to ensure that it is the format we can actually use. llvm-svn: 254476
* Temporarily add expectedFailureFreeBSD to tests that fail to detect Clang on ↵Ed Maste2015-11-241-0/+1
| | | | | | | | | | FreeBSD On FreeBSD we may get Clang via CC=cc or CC=/usr/bin/cc. llvm.org/pr25626 llvm-svn: 254006
* Fix up LLDB for a change in the way clang represents anonymous unions such ↵Enrico Granata2015-11-193-0/+55
| | | | | | that the 'frame variable' command can still find the members of such union as if they were top-level variables in the current scope llvm-svn: 253613
* Fix some issues with swig & string conversion.Zachary Turner2015-11-181-0/+3
| | | | | | | | | | | | | | | | | | | | This patch fixes two issues: 1) Popen needs to be used with universal_newlines=True by default. This elicits automatic decoding from bytes -> string in Py3, and has no negative effects in other Py versions. 2) The swig typemaps for converting between string and (char*, int) did not work correctly when the length of the string was 0, indicating an error. In this case we would try to construct a string from uninitialized data. 3) Ironically, the bug mentioned in #2 led to a test passing on Windows that was actually broken, because the test was written such that the assertion was never even getting checked, so it passed by default. So we additionally fix this test to also fail if the method errors. By fixing this test it's now broken on Windows, so we also xfail it. llvm-svn: 253487
* Fixed a testcase problem where disassembly would fail for nameless functions.Sean Callanan2015-11-131-1/+2
| | | | llvm-svn: 253101
* Fix multiple symbol lookup in the same namespaceEugene Leviant2015-11-132-8/+44
| | | | llvm-svn: 253028
* Remove `use_lldb_suite` from the package, and don't import it anymore.Zachary Turner2015-11-0318-18/+18
| | | | | | | | | | | | | | | | This module was originally intended to be imported by top-level scripts to be able to find the LLDB packages and third party libraries. Packages themselves shouldn't need to import it, because by the time it gets into the package, the top-level script should have already done this. Indeed, it was just adding the same values to sys.path multiple times, so this patch is essentially no functional change. To make sure it doesn't get re-introduced, we also delete the `use_lldb_suite` module from `lldbsuite/test`, although the original copy still remains in `lldb/test` llvm-svn: 251963
* Tighten up sys.path, and use absolute imports everywhere.Zachary Turner2015-11-0332-67/+69
| | | | | | | | | | | | | | | | | | | | For convenience, we had added the folder that dotest.py was in to sys.path, so that we could easily write things like `import lldbutil` from anywhere and any test. This introduces a subtle problem when using Python's package system, because when unittest2 imports a particular test suite, the test suite is detached from the package. Thus, writing "import lldbutil" from dotest imports it as part of the package, and writing the same line from a test does a fresh import since the importing module was not part of the same package. The real way to fix this is to use absolute imports everywhere. Instead of writing "import lldbutil", we need to write "import lldbsuite.test.util". This patch fixes up that and all other similar cases, and additionally removes the script directory from sys.path to ensure that this can't happen again. llvm-svn: 251886
* Move lldb/test to lldb/packages/Python/lldbsuite/test.Zachary Turner2015-10-28106-0/+4295
This is the conclusion of an effort to get LLDB's Python code structured into a bona-fide Python package. This has a number of benefits, but most notably the ability to more easily share Python code between different but related pieces of LLDB's Python infrastructure (for example, `scripts` can now share code with `test`). llvm-svn: 251532
OpenPOWER on IntegriCloud