Hello, I have a function and a struct:
void foo(ref Data data) { ... }
struct Data { int a; string text; }
How to pass struct into function without naming its type? This doesn't work:
foo({1234, "Hello!"});
Andrey via Digitalmars-d-learn Mon, 20 Aug 2018 02:26:07 -0700
Hello, I have a function and a struct:
void foo(ref Data data) { ... }
struct Data { int a; string text; }
How to pass struct into function without naming its type? This doesn't work:
foo({1234, "Hello!"});