]> git.ipfire.org Git - thirdparty/gcc.git/commit
Change lookup_hir_extern_item return type
authorPierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
Thu, 2 May 2024 11:44:10 +0000 (13:44 +0200)
committerP-E-P <32375388+P-E-P@users.noreply.github.com>
Fri, 17 May 2024 15:28:30 +0000 (15:28 +0000)
commitfa24d0d08eb385df313beab7dd7c8a1091c216c4
tree012f21a6eadcc1dd5f97f85382c98801de0f763f
parent310081b7d629e4640d0b962f727ac4249bd51e25
Change lookup_hir_extern_item return type

Wrap the return type with an optional and make the return type a pair
with the parent hid.

gcc/rust/ChangeLog:

* backend/rust-compile-resolve-path.cc (HIRCompileBase::query_compile):
Adapt code around new return type.
* checks/errors/rust-const-checker.cc (ConstChecker::check_function_call):
Likewise.
* checks/errors/rust-unsafe-checker.cc (UnsafeChecker::check_use_of_static):
Likewise.
(UnsafeChecker::check_function_call): Likewise.
* typecheck/rust-type-util.cc (query_type): Likewise.
* util/rust-hir-map.cc (Mappings::insert_hir_extern_item): Likewise.
(Mappings::lookup_hir_extern_item): Change return type.
* util/rust-hir-map.h: Update the function's prototype.

Signed-off-by: Pierre-Emmanuel Patry <pierre-emmanuel.patry@embecosm.com>
gcc/rust/backend/rust-compile-resolve-path.cc
gcc/rust/checks/errors/rust-const-checker.cc
gcc/rust/checks/errors/rust-unsafe-checker.cc
gcc/rust/typecheck/rust-type-util.cc
gcc/rust/util/rust-hir-map.cc
gcc/rust/util/rust-hir-map.h