On 2019-05-01 14:47, Robert M. Münch wrote:
I use some C library that uses structs and many functions that use
pointer to structs as arguments:
struct A {...};
myfunc(A *myA);
In C you can do this to get a lvalue:
myfunc(&(A){...});
In D this doesn't work and I get an "is not an lvalue and c
On Thursday, 2 May 2019 at 07:11:37 UTC, Robert M. Münch wrote:
On 2019-05-01 19:13:54 +, Alex said:
Doesn't work because this seems to kick in some D releated
run-time stuff which lead to unresolved externals during
linking:
error LNK2001: Nicht aufgelöstes externes Symbol "...__initZ".
On 2019-05-01 19:13:54 +, Alex said:
Doesn't work because this seems to kick in some D releated run-time
stuff which lead to unresolved externals during linking:
error LNK2001: Nicht aufgelöstes externes Symbol "...__initZ".
error LNK2001: Nicht aufgelöstes externes Symbol
"...__xtoHashFN
On Wednesday, 1 May 2019 at 14:59:48 UTC, Robert M. Münch wrote:
On 2019-05-01 14:23:37 +, Alex said:
However, to rebuild the same structure, auto ref parameters
may be appropriate.
https://dlang.org/spec/template.html#auto-ref-parameters
That would need me to change myfunc which is not
On 2019-05-01 14:23:37 +, Alex said:
On Wednesday, 1 May 2019 at 12:47:22 UTC, Robert M. Münch wrote:
I use some C library that uses structs and many functions that use
pointer to structs as arguments:
struct A {...};
myfunc(A *myA);
In C you can do this to get a lvalue:
myfunc(&(A){...
On Wednesday, 1 May 2019 at 12:47:22 UTC, Robert M. Münch wrote:
I use some C library that uses structs and many functions that
use pointer to structs as arguments:
struct A {...};
myfunc(A *myA);
In C you can do this to get a lvalue:
myfunc(&(A){...});
In D this doesn't work and I get an "i
I use some C library that uses structs and many functions that use
pointer to structs as arguments:
struct A {...};
myfunc(A *myA);
In C you can do this to get a lvalue:
myfunc(&(A){...});
In D this doesn't work and I get an "is not an lvalue and cannot be modified".
What's the correct D-ish