summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPierre-Marie de Rodat <derodat@adacore.com>2017-03-22 14:48:04 (GMT)
committerPierre-Marie de Rodat <derodat@adacore.com>2018-03-23 18:02:25 (GMT)
commit4a20baa3ea5efd1dae78d0f85c22ccd7d62c184b (patch)
treee6664e7f71344dda875849e5ea887114c32fb9e0
parent4bdbb50ec22952dc799c88e40fc64d76b285dbe5 (diff)
downloadcv2pdb-4a20baa3ea5efd1dae78d0f85c22ccd7d62c184b.zip
cv2pdb-4a20baa3ea5efd1dae78d0f85c22ccd7d62c184b.tar.gz
cv2pdb-4a20baa3ea5efd1dae78d0f85c22ccd7d62c184b.tar.bz2
DWARF_InfoData: track the DW_AT_language attribute
-rw-r--r--src/readDwarf.cpp1
-rw-r--r--src/readDwarf.h2
2 files changed, 3 insertions, 0 deletions
diff --git a/src/readDwarf.cpp b/src/readDwarf.cpp
index 690cb8e..e5895fc 100644
--- a/src/readDwarf.cpp
+++ b/src/readDwarf.cpp
@@ -500,6 +500,7 @@ bool DIECursor::readNext(DWARF_InfoData& id, bool stopAtNull)
case DW_AT_data_member_location: id.member_location = a; break;
case DW_AT_location: id.location = a; break;
case DW_AT_frame_base: id.frame_base = a; break;
+ case DW_AT_language: assert(a.type == Const); id.language = a.cons; break;
}
}
diff --git a/src/readDwarf.h b/src/readDwarf.h
index 4d077c8..8d98a00 100644
--- a/src/readDwarf.h
+++ b/src/readDwarf.h
@@ -163,6 +163,7 @@ struct DWARF_InfoData
DWARF_Attribute frame_base;
long upper_bound;
long lower_bound;
+ unsigned language;
void clear()
{
@@ -191,6 +192,7 @@ struct DWARF_InfoData
frame_base.type = Invalid;
upper_bound = 0;
lower_bound = 0;
+ language = 0;
}
void merge(const DWARF_InfoData& id)