I have this Rust function:
pub fn abc(x: &dyn Fn()) {
x()
}
When I compile it with Rust 1.63.0 on Godbolt Compiler Explorer I get this generated x86-64 assembly code:
example::abc:
push rax
call qword ptr [rsi + 40]
pop rax
ret
Where is the offset 40 coming from? I want to get an underlying understanding of this generated assembly code.