mirror of
https://github.com/apple/container.git
synced 2026-07-13 04:57:08 +00:00
beb1592c04
This adds a swift Decoder that decodes from a swift-configuration ConfigSnapshot, and adds the ability to modify how select types are decoded within the ConfigSnapshotDecoder. This is something that JSONEncoder already does with URLs specifically, however this enables users to configure this behavior for any arbitrary type regardless of existing Codable conformance. The decoder will help us expand on top of (pr: https://github.com/apple/container/pull/1425), which switches user configuration to TOML. With this PR we will be able to provide a multi layered TOML if desired, allowing container to ship a default TOML instead of encoding them in code constants.