Commit Graph

7 Commits

Author SHA1 Message Date
Jordan Rose
f19815b938 swift: Add a low-level helper invokeFnReturningValueByPointer
...and use it to avoid having to name return types for bridge
functions, which return by out-parameter.
2025-10-14 11:22:22 -07:00
Jordan Rose
9e13263581 Switch to swift-format for formatting instead of swiftformat
swift-format is owned by the Swift project and is generally less
opinionated than swiftformat (but better at formatting to a limited
line length).
2025-06-25 11:24:57 -07:00
Alex Konradi
33b8e9c3d8 Use strong pointer types for Swift bridge
Wrap the raw pointers exposed across the bridge as named types that approximate 
Swift's OpaquePointer?. Parameterize NativeHandleOwner with the native handle 
type.
2024-12-18 10:00:07 -05:00
Jordan Rose
e2b453fb18 swift: Initial audit for Sendable
- All public Swift-defined structs except CdsiLookupResponse,
  which wraps LookupResponseEntryList, which can *probably* be made
  Sendable but I didn't spend time on it.

- All public Swift-defined enums except those being used purely as
  namespaces.

- All zkgroup types, since they are immutable and can be serialized
  and deserialized to send them anyway

- ServiceId and its subclasses, an immutable class hierarchy

- ProtocolAddress, PinHash, SenderCertificate and ServerCertificate,
  and all public and private Key types, immutable wrappers around
  immutable Rust objects

More of our wrapper types could be made Sendable as well if there's a
need to. See CODING_GUIDELINES for more info.
2024-10-23 13:10:16 -07:00
Jordan Rose
2feac3495b swift: Replace last use of NSLog with new logging protocol 2024-07-08 14:49:22 -07:00
Harry
72aae8c00f Remove SignalCoreKit dependency in libsignal 2024-06-26 09:44:22 -07:00
Jordan Rose
7dc63b99af ffi: Expose cancellation to Swift 2024-05-17 11:30:24 -07:00