From: Pierre-Emmanuel Patry <pierre-emmanuel.pa...@embecosm.com>

Inherent impl has a type it applies to. This type
was not visited and thus not resolved.

gcc/rust/ChangeLog:

        * resolve/rust-default-resolver.cc (DefaultResolver::visit): Visit
        inherent impl type.

Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.pa...@embecosm.com>
---
 gcc/rust/resolve/rust-default-resolver.cc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/gcc/rust/resolve/rust-default-resolver.cc 
b/gcc/rust/resolve/rust-default-resolver.cc
index 393994808ee..c54cabad2e5 100644
--- a/gcc/rust/resolve/rust-default-resolver.cc
+++ b/gcc/rust/resolve/rust-default-resolver.cc
@@ -115,6 +115,7 @@ void
 DefaultResolver::visit (AST::InherentImpl &impl)
 {
   auto inner_fn = [this, &impl] () {
+    visit (impl.get_type ());
     for (auto &item : impl.get_impl_items ())
       item->accept_vis (*this);
   };
-- 
2.45.2

Reply via email to