0

I am trying to call a C function in swift

int getValueFromC(char ** aValue);

In swift I see the "Type" is

UnsafeMutablePointer<UnsafeMutablePointer<Int8>?>

So i would call the function i swift using:

getValueFrom(myStringPointerPointer)

where myStringPointerPointer value would be at least initialised

Eric Aya
  • 69,000
  • 34
  • 174
  • 243
Reimond Hill
  • 3,445
  • 27
  • 45

1 Answers1

1
var aVar:UnsafeMutablePointer<CChar>? = nil
let aIntVar = getValueFromC(&aVar)
Reimond Hill
  • 3,445
  • 27
  • 45