Post #2564798
2026-04-30 10:15 UTC
@Ambraven@social.mochi.academy Your C++ code uses temporary default as reference; #Rust doesn't have them... unfortunately.
The closest semantically would be IMHO:
```
fn foo(t: Option) {
fn inner_foo(t: &T) {
t.toto();
}
inner_foo(t.unwrap_or(&T::default()));
}
```
#Cpp
Replies (0)
No replies.