aboutsummaryrefslogtreecommitdiff
path: root/gcc/rust/backend/rust-compile-resolve-path.cc
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2022-12-04 19:14:59 +0000
committerGitHub <noreply@github.com>2022-12-04 19:14:59 +0000
commit22329b03a6e0a3381d907745205012cf290b3c2a (patch)
treef6c9616a3c3ab3c69c5d5be7a020934162fb05e7 /gcc/rust/backend/rust-compile-resolve-path.cc
parent402118688f56d88d213572ee55a4245eec83b25f (diff)
parent071e8b001c7834c38dc4db697dd10d26eba67149 (diff)
downloadgcc-22329b03a6e0a3381d907745205012cf290b3c2a.zip
gcc-22329b03a6e0a3381d907745205012cf290b3c2a.tar.gz
gcc-22329b03a6e0a3381d907745205012cf290b3c2a.tar.bz2
Merge #1676
1676: Fix regressions in 32 bit mode and gcc4.8 builds r=CohenArthur a=philberty This reverts commit 9657c328d0cdda49b7985c3ee727781a387e128b. This reverts commit fc59d137491ce393797dfec1d8cd5251a41b5f67. Co-authored-by: Philip Herron <philip.herron@embecosm.com>
Diffstat (limited to 'gcc/rust/backend/rust-compile-resolve-path.cc')
-rw-r--r--gcc/rust/backend/rust-compile-resolve-path.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/gcc/rust/backend/rust-compile-resolve-path.cc b/gcc/rust/backend/rust-compile-resolve-path.cc
index 7becdf7..f89da2b 100644
--- a/gcc/rust/backend/rust-compile-resolve-path.cc
+++ b/gcc/rust/backend/rust-compile-resolve-path.cc
@@ -33,20 +33,20 @@ void
ResolvePathRef::visit (HIR::QualifiedPathInExpression &expr)
{
resolved = resolve (expr.get_final_segment ().get_segment (),
- expr.get_mappings (), expr.get_locus ());
+ expr.get_mappings (), expr.get_locus (), true);
}
void
ResolvePathRef::visit (HIR::PathInExpression &expr)
{
resolved = resolve (expr.get_final_segment ().get_segment (),
- expr.get_mappings (), expr.get_locus ());
+ expr.get_mappings (), expr.get_locus (), false);
}
tree
ResolvePathRef::resolve (const HIR::PathIdentSegment &final_segment,
const Analysis::NodeMapping &mappings,
- Location expr_locus)
+ Location expr_locus, bool is_qualified_path)
{
TyTy::BaseType *lookup = nullptr;
bool ok = ctx->get_tyctx ()->lookup_type (mappings.get_hirid (), &lookup);
@@ -157,8 +157,8 @@ ResolvePathRef::resolve (const HIR::PathIdentSegment &final_segment,
}
// let the query system figure it out
- tree resolved_item
- = query_compile (ref, lookup, final_segment, mappings, expr_locus);
+ tree resolved_item = query_compile (ref, lookup, final_segment, mappings,
+ expr_locus, is_qualified_path);
if (resolved_item != error_mark_node)
{
TREE_USED (resolved_item) = 1;
@@ -170,7 +170,7 @@ tree
HIRCompileBase::query_compile (HirId ref, TyTy::BaseType *lookup,
const HIR::PathIdentSegment &final_segment,
const Analysis::NodeMapping &mappings,
- Location expr_locus)
+ Location expr_locus, bool is_qualified_path)
{
HIR::Item *resolved_item = ctx->get_mappings ()->lookup_hir_item (ref);
HirId parent_block;