]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Visit type during resolution of inherent impl
authorPierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Thu, 18 Apr 2024 20:30:56 +0000 (22:30 +0200)
committerP-E-P <32375388+P-E-P@users.noreply.github.com>
Mon, 22 Apr 2024 16:00:27 +0000 (16:00 +0000)
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.patry@embecosm.com>
gcc/rust/resolve/rust-default-resolver.cc

index 393994808ee0a087e3d6bd7f2bc45bf0c427493d..c54cabad2e5dc7b27952945375a104258f502770 100644 (file)
@@ -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);
   };