I have a C struct havethat contains a pointer, all defined in a c include fileC header:
struct testA {
int iSignal;
struct testB *test;
};
struct testB {
int iPro;
};
Then I have a swift fileSwift program to initialize an instance of this struct:
var a = testA()
var b = testB()
a.test = &b // this line error
But I get the following error: '&' used with non-inout argument of type 'UnsafeMutablePointer'
'&' used with non-inout argument of type 'UnsafeMutablePointer<testB>'
Anyone canCan anyone help ?