Hamilton Chapman
aed2b2ad7a
Fix some warnings about encoding and decoding Data and Date types
2024-10-28 17:51:13 +00:00
Dimitri Bouniol
2b771ddd16
Added the ability to specify a maximum depth for CBOR decoding
...
Closes #92
2024-03-26 16:12:07 +00:00
Hamilton Chapman
d84829daa5
Add a test for the nested optional array of a Codable decoding incorrectly
2022-12-04 09:51:20 -08:00
Ahmed Elmoughazy
d5f9b644bb
* solving crashing problem when decoding optional UnkeyedContainer.
...
context:
- calling decodeIfPresent on optional arrays, cause the application to crash because of Force unwrap.
2022-12-04 09:51:20 -08:00
Hamilton Chapman
5aa8f6c40b
Fix Codable-based decoding of indefinite maps and arrays.
...
We weren't moving the index along for the extra break byte (0xff), but now we
are.
Fixes : #78
2022-03-11 13:57:44 +00:00
Hamilton Chapman
a79e0ca348
Fix types being used in typeMismatch errors
2022-03-11 13:57:44 +00:00
Hamilton Chapman
1fb6c0d326
Fix issue when trying to decode a mismatched type as a dictionary or an array
...
would lead to an empty container being decoded instead of an error being thrown.
We now correctly throw a `DecodingError.typeMismatch` error in cases like this.
Fixes : #59
2022-03-11 13:57:44 +00:00
Hamilton Chapman
36f89e5dad
Fix an issue where decoding would fail if there was a property in a
...
`Decodable`-conforming type that was an optional array (`Optional<Array<T>>`)
and the value was an empty array.
2022-03-11 13:57:44 +00:00
Hamilton Chapman
80a90c3a60
Restructure and update repository to work with modern Swift Package Manager
...
conventions.
2021-12-15 18:10:44 +00:00