You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ole Begemann came up with a nice use case for fixing a shortcoming of Codable when dealing with Dictionaries that have a String based Enum key. Currently, these unexpectedly encode/decode as arrays rather than dictionary representations
If this is too specific of a use case, it might not make sense to include it, but I believe it solves a real problem that I have faced with Codable. What do you think about including this or a similar implementation? If you think it's useful, this package feels like a good home for it.
The text was updated successfully, but these errors were encountered:
That's super interesting, thanks for the tip! The accompanying bugs.swift.org post has a lot of good info on that as well. I'll spend some time digging into these nuances and see what I can come up with.
@Stevenmagdy Appreciate the offer but no thanks. I'm still on the fence with supporting something similar to KeyedContainer. There are a lot of bugs-used-as-features in regards to Dictionary de/en/coding right now so I've been hoping to see Swift make a decision here or tell us this is the bed we must lie in.
Ole Begemann came up with a nice use case for fixing a shortcoming of Codable when dealing with Dictionaries that have a String based Enum key. Currently, these unexpectedly encode/decode as arrays rather than dictionary representations
https://gist.github.com/ole/5c31ca9e2919c815029784ef3b8fdc0d
If this is too specific of a use case, it might not make sense to include it, but I believe it solves a real problem that I have faced with Codable. What do you think about including this or a similar implementation? If you think it's useful, this package feels like a good home for it.
The text was updated successfully, but these errors were encountered: