```
void main() {
foo(Asdf());
}
void foo(in Asdg x) {}
struct Asdf {}
struct Asdg {
int a;
int b;
int c;
int d;
int e;
}
```
Compiling with `dmd a.d -preview=in` I get this error message:
```
a.d(2): Error: function `foo` is not callable using argument types `(Asdf)`
a.d(2): cannot pass rvalue argument `Asdf()` of type `Asdf` to parameter `in Asdg x`
a.d(5): `a.foo(in Asdg x)` declared here
```
The error message appears to be complaining about an rvalue. The error is actually just due to using the wrong type, and an rvalue of the correct type would work.
The issue does not reproduce if the correct type has less than 5 fields.
Comment #1 by robert.schadek — 2024-12-13T19:37:51Z