llvm-project/lldb/unittests/SymbolFile
Raphael Isemann 73951a11c6 [lldb] Add sanity check to CreateDeclContext and fixed illformed CompilerContext in ClangExpressionDeclMap.
This adds a check that the ClangASTContext actually fits to the
DeclContext that we want to create a CompilerDeclContext for. If
the ClangASTContext (and its associated ASTContext) does not fit
to the DeclContext (that is, the DeclContext wasn't created by the
ASTContext), all computations using this malformed CompilerDeclContext
will yield unpredictable results.

Also fixes the only place that actually hits this assert which is the
construction of a CompilerDeclContext in ClangExpressionDeclMap
where we pass an unrelated ASTContext instead of the ASTContext
of the current expression.

I had to revert my previous change to DWARFASTParserClangTests.cpp
back to using the unsafe direct construction of CompilerDeclContext
as this assert won't work if the DeclContext we pass isn't a valid
DeclContext in the first place.
2019-12-23 11:48:02 +01:00
..
DWARF [lldb] Add sanity check to CreateDeclContext and fixed illformed CompilerContext in ClangExpressionDeclMap. 2019-12-23 11:48:02 +01:00
NativePDB PostfixExpression: Use signed integers in IntegerNode 2019-05-07 15:58:20 +00:00
PDB [lldb] Fix windows build after getASTContext() change 2019-12-21 23:27:27 +01:00
CMakeLists.txt [PDB] Fix location retrieval for function local variables and arguments that are 2019-02-01 10:01:18 +00:00