diff options
author | Owen Avery <powerboat9.gamer@gmail.com> | 2025-01-11 00:15:05 -0500 |
---|---|---|
committer | P-E-P <32375388+P-E-P@users.noreply.github.com> | 2025-04-28 11:13:51 +0000 |
commit | 7409c28ee0aa6c43149201e79969031a3021a6dd (patch) | |
tree | 643eb71d942a6f23160c7b0ce8cfb9a266cb02a2 /gcc/rust/resolve/rust-early-name-resolver-2.0.cc | |
parent | b22c7d8df0b3adb17d26f302d192bef1816d5bca (diff) | |
download | gcc-7409c28ee0aa6c43149201e79969031a3021a6dd.zip gcc-7409c28ee0aa6c43149201e79969031a3021a6dd.tar.gz gcc-7409c28ee0aa6c43149201e79969031a3021a6dd.tar.bz2 |
Some assorted tweaks and bug fixes
gcc/rust/ChangeLog:
* ast/rust-ast-visitor.cc
(DefaultASTVisitor::visit): Visit the loop labels of
WhileLetLoopExpr instances before visiting their scrutinee
expressions.
* resolve/rust-early-name-resolver-2.0.cc
(Early::resolve_glob_import): Pass the glob import's path
directly to NameResolutionContext::resolve_path.
* resolve/rust-toplevel-name-resolver-2.0.cc
(TopLevel::visit): Remove unnecessary call to
Identifier::as_string.
(flatten_glob): Improve handling of cases where a glob use tree
has no path.
Signed-off-by: Owen Avery <powerboat9.gamer@gmail.com>
Diffstat (limited to 'gcc/rust/resolve/rust-early-name-resolver-2.0.cc')
-rw-r--r-- | gcc/rust/resolve/rust-early-name-resolver-2.0.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/rust/resolve/rust-early-name-resolver-2.0.cc b/gcc/rust/resolve/rust-early-name-resolver-2.0.cc index 3470a73..3060b29 100644 --- a/gcc/rust/resolve/rust-early-name-resolver-2.0.cc +++ b/gcc/rust/resolve/rust-early-name-resolver-2.0.cc @@ -70,8 +70,7 @@ Early::go (AST::Crate &crate) bool Early::resolve_glob_import (NodeId use_dec_id, TopLevel::ImportKind &&glob) { - auto resolved - = ctx.resolve_path (glob.to_resolve.get_segments (), Namespace::Types); + auto resolved = ctx.resolve_path (glob.to_resolve, Namespace::Types); if (!resolved.has_value ()) return false; |