public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r13-6171] gccrs: rust-ast-resolve-item: Add note about resolving glob uses
@ 2023-02-21 11:56 Arthur Cohen
  0 siblings, 0 replies; only message in thread
From: Arthur Cohen @ 2023-02-21 11:56 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:295cd26508882551111817f2216ecfbb2f4c467b

commit r13-6171-g295cd26508882551111817f2216ecfbb2f4c467b
Author: Arthur Cohen <arthur.cohen@embecosm.com>
Date:   Tue Oct 11 11:39:15 2022 +0200

    gccrs: rust-ast-resolve-item: Add note about resolving glob uses
    
    gcc/rust/ChangeLog:
    
            * resolve/rust-ast-resolve-item.cc (ResolveItem::visit): Add note for
            glob import resolving.

Diff:
---
 gcc/rust/resolve/rust-ast-resolve-item.cc | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/gcc/rust/resolve/rust-ast-resolve-item.cc b/gcc/rust/resolve/rust-ast-resolve-item.cc
index e5eb6e491e3..193e6834334 100644
--- a/gcc/rust/resolve/rust-ast-resolve-item.cc
+++ b/gcc/rust/resolve/rust-ast-resolve-item.cc
@@ -968,6 +968,14 @@ ResolveItem::visit (AST::UseDeclaration &use_item)
 {
   auto to_resolve = flatten_use_dec_to_paths (use_item);
 
+  // FIXME: I think this does not actually resolve glob use-decls and is going
+  // the wrong way about it. RFC #1560 specifies the following:
+  //
+  // > When we find a glob import, we have to record a 'back link', so that when
+  // a public name is added for the supplying module, we can add it for the
+  // importing module.
+  //
+  // Which is the opposite of what we're doing if I understand correctly?
   for (auto &path : to_resolve)
     ResolvePath::go (&path);
 }

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-02-21 11:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-21 11:56 [gcc r13-6171] gccrs: rust-ast-resolve-item: Add note about resolving glob uses Arthur Cohen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).