[Lldb-commits] [PATCH] D13066: Make DWARFASTParserClang::ParseChildMembers return a bool.
Siva Chandra via lldb-commits
lldb-commits at lists.llvm.org
Tue Sep 22 13:18:16 PDT 2015
sivachandra created this revision.
sivachandra added a reviewer: clayborg.
sivachandra added a subscriber: lldb-commits.
The return value is false if any of the child members have incomplete
type info. This helps in cases like these:
If a file with the above code is compiled with a modern clang but without
the -fno-limit-debug-info (or similar) option, then the DWARF has only
a forward declration for std::string. In which case, the type for
"class Foo" cannot be completed. If LLDB does not detect that a child
member has incomplete type, then it wrongly conveys to clang (the LLDB
compiler) that "class Foo" is complete, and consequently crashes due to
an assertion failure in clang when running commands like "p f" or
"frame var f".
After the change to DWARFASTParserClang::ParseChildMember,
DWARFASTParserClang::CompleteTypeFromDWARF returns false if
DWARFASTParserClang::ParseChildMember returns false.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 6752 bytes
Desc: not available
More information about the lldb-commits