<!-- Hi,
     Thank you for your contribution!
     Please assist reviewers by filling out this template. -->
## Rationale

<!-- Additional comments go here. -->


### Feature request or issue tracking

<!-- Please update the issue number (e.g. `#10974`) below, if applicable.
     Otherwise, feel free to remove this section. -->

Closes #10974.


## Pre-review checklist

- [ ] I have performed a self-review of my code.
- [ ] If my PR fixes a bug or introduces a new feature, I have added thorough tests.
- [ ] If my changes are non-trivial and do not concern a reported issue, I have added a changelog entry.


### LLM/AI disclosure

<!-- If applicable, please keep the corresponding option only.
     (This section can be removed for hand-written code.) -->

This PR was written with the assistance of an LLM/AI.
This PR was written entirely by an LLM/AI.
