With -gmodules, we have been having a harder time always finding a type when we need one.
We have seen cases where we have been unable to find an argument type for a function, or we find one from another language, and then we try to create a function type by calling: lldb_private::ClangASTContext::CreateFunctionType(clang::ASTContext*, lldb_private::CompilerType const&, lldb_private::CompilerType const*, unsigned int, bool, unsigned int) This fix will ensure that all arguments to lldb_private::ClangASTContext::CreateFunctionType() are in order by checking: - AST is valid - if arguments are specified we have a valid argument array - return type is valid - return type is a clang type - all argument types are valid - all argument types are clang types If any of these fail, we return an invalid CompilerType. If we don't return an invalid type, clang will crash anyway, and LLDB must not crash even in the presence of bad or missing debug info. <rdar://problem/25172715> llvm-svn: 270932
Loading
Please register or sign in to comment