Passing an Array of Strings from Swift to C

Swift has built-in support for bridging native strings to C strings, but this doesn’t include transparent bridging of arrays of strings to arrays of C strings. Here I discuss an internal helper function the Swift standard library uses for this purpose.

Similar

Initializers in Swift

Let’s take a look at one of the core aspects of object-oriented programming — initialization. What characteristics should an initializer ideally have, and what sort of techniques could be useful in order to keep our initializers simple and predictable? (more…)

Read more »

DIY in-memory cache in Swift

Caches are everywhere. Starting from hardware chips, and up to network protocols, devices, systems and applications are using caches to optimize for performance. In iOS, developers are well familia… (more…)

Read more »