Summary
The DictionaryCoding module (in Packages/AtLeastKit/Sources/DictionaryCoding/) relies heavily on Foundation types that are not available on non-Darwin platforms:
NSMutableDictionary, NSMutableArray, NSNull, NSNumber
NSDecimalNumber, NSURL, NSDate, NSData
CFGetTypeID, CFBooleanGetTypeID, CFUUID (Darwin-only CoreFoundation)
Impact
AtLeastKit targets cross-platform testing (macOS, iOS, watchOS, tvOS, visionOS). While all current targets are Apple platforms, the Foundation dependency means:
DictionaryCoding cannot be tested on Linux CI runners
- If AtLeastKit ever needs to support non-Apple platforms, this module would need significant rework
Options to evaluate
- Document the limitation — add a note that DictionaryCoding is Darwin-only by design
- Add
#if canImport(ObjectiveC) guards — provide a stub or alternative implementation for non-Darwin
- Replace with an external package — evaluate existing Swift packages that solve Dictionary ↔ Codable bridging cross-platform
Context
Introduced in PR #172 (v1.0.0-beta.5) for WatchConnectivity message serialization via Messagable+Codable.
Summary
The
DictionaryCodingmodule (inPackages/AtLeastKit/Sources/DictionaryCoding/) relies heavily on Foundation types that are not available on non-Darwin platforms:NSMutableDictionary,NSMutableArray,NSNull,NSNumberNSDecimalNumber,NSURL,NSDate,NSDataCFGetTypeID,CFBooleanGetTypeID,CFUUID(Darwin-only CoreFoundation)Impact
AtLeastKit targets cross-platform testing (macOS, iOS, watchOS, tvOS, visionOS). While all current targets are Apple platforms, the Foundation dependency means:
DictionaryCodingcannot be tested on Linux CI runnersOptions to evaluate
#if canImport(ObjectiveC)guards — provide a stub or alternative implementation for non-DarwinContext
Introduced in PR #172 (v1.0.0-beta.5) for WatchConnectivity message serialization via
Messagable+Codable.