Cannot use explicit lifetime in call to mem::size_of
#77064
Labels
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Hello! I've tried to search for this error in the open issues but couldn't find anything, sorry if I've missed something. Below is a minimal example of the issue — it is to do with using an explicit
&'a
lifetime in the call tomem::size_of
. If I replace the call withmem::size_of::<&i32>()
(notice&
rather than&'a
), it compiles without any errors.Code
Meta
rustc --version --verbose
:Error output
Backtrace
The text was updated successfully, but these errors were encountered: