Skip to content

Commit a64387b

Browse files
committed
Emit DW_AT_external if applicable
1 parent 98eaaed commit a64387b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/debuginfo/mod.rs

+4
Original file line numberDiff line numberDiff line change
@@ -221,6 +221,10 @@ impl DebugContext {
221221
entry.set(gimli::DW_AT_decl_file, AttributeValue::FileIndex(Some(file_id)));
222222
entry.set(gimli::DW_AT_decl_line, AttributeValue::Udata(line));
223223

224+
if tcx.is_reachable_non_generic(instance.def_id()) {
225+
entry.set(gimli::DW_AT_external, AttributeValue::FlagPresent);
226+
}
227+
224228
// FIXME set DW_AT_external as appropriate
225229

226230
FunctionDebugContext {

0 commit comments

Comments
 (0)