Skip to content

Commit 30cb296

Browse files
committed
[DWARF Import] Do not wrap function parameter types in named type references
1 parent 5999964 commit 30cb296

File tree

1 file changed

+5
-16
lines changed

1 file changed

+5
-16
lines changed

plugins/dwarf/dwarf_import/src/die_handlers.rs

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -388,22 +388,11 @@ pub(crate) fn handle_function<R: ReaderType>(
388388
})?;
389389
let child_type = child_debug_type.get_type();
390390

391-
// If this is a typedef, make sure we reference it instead of resolving to the underlying type
392-
if let Some(ntr) = child_type.get_named_type_reference() {
393-
let typedef_type = Type::named_type_from_type(ntr.name(), &child_type);
394-
395-
parameters.push(FunctionParameter::new(
396-
typedef_type,
397-
name.unwrap_or_default(),
398-
None,
399-
));
400-
} else {
401-
parameters.push(FunctionParameter::new(
402-
child_type,
403-
name.unwrap_or_default(),
404-
None,
405-
));
406-
}
391+
parameters.push(FunctionParameter::new(
392+
child_type,
393+
name.unwrap_or_default(),
394+
None,
395+
));
407396
} else if child.entry().tag() == constants::DW_TAG_unspecified_parameters {
408397
variable_arguments = true;
409398
}

0 commit comments

Comments
 (0)