Skip to content
Commit a5d1f62d authored by Greg Clayton's avatar Greg Clayton
Browse files

Always try to read DW_TAG_typedef types from DWO files first if we can.

A lot of C code uses code like:

typedef struct 
{
   int a;
} FooType;
          
This creates debug info with an anonymous struct (a DW_TAG_structure_type with no DW_AT_name) and then a DW_TAG_typedef that points to the anonymous structure type. When a typedef is from a module and clang uses -gmodules and -fmodules, then we can end up trying to resolve an anonymous structure type in a DWO symbol file. This doesn't work very well when the structuture has no name, so we now check if a typedef comes from a module, and we directly resolve the typedef type in the module and copy it over. The version we copy from the module of course is correctly able to find the structure in the DWO symbol file, so this fixes the issues we run into.

<rdar://problem/24092915> 

llvm-svn: 258443
parent 18ec96f0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment