Skip to content

Commit

Permalink
ast: Lower 'for' lifetimes
Browse files Browse the repository at this point in the history
gcc/rust/ChangeLog:

	* hir/rust-ast-lower-type.cc (ASTLoweringType::visit): For lifetimes.

Signed-off-by: Jakub Dupak <[email protected]>
  • Loading branch information
jdupak authored and CohenArthur committed Dec 27, 2023
1 parent 205151a commit b9fccab
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions gcc/rust/hir/rust-ast-lower-type.cc
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,13 @@ ASTLoweringType::visit (AST::BareFunctionType &fntype)
{
bool is_variadic = false;
std::vector<HIR::LifetimeParam> lifetime_params;
for (auto &lifetime_param : fntype.get_for_lifetimes ())
{
auto generic_param = ASTLowerGenericParam::translate (&lifetime_param);
lifetime_params.push_back (
*static_cast<HIR::LifetimeParam *> (generic_param));
}

HIR::FunctionQualifiers qualifiers
= lower_qualifiers (fntype.get_function_qualifiers ());

Expand Down

0 comments on commit b9fccab

Please sign in to comment.