3 Commits

Author SHA1 Message Date
Tony Parker
8c865b6138
Base64 must relinquish use of OutputBuffer on error (#700) 2024-06-24 15:58:34 -07:00
Guillaume Lessard
3e268afe74
Implement base64 for Data in Swift (#337)
* [base64] initial Base-64 re-implementation

* Add BufferView._assertBounds() functions

- they act the same as the _checkBounds() functions
- but only in debug mode

* Improve BufferView slicing

- when all the necessary checking has been done, the BufferView initializer doesn’t need to validate the buffer length another time.

* remove premature reference to typealias

* add the `unsafe` particle to an initializer argument label

* [base64] modify Base64 with `OutputBuffer` and `BufferView`

* remove unused bits in OutputBuffer

* express a cascaded if statement as a switch

* make internal decoding initializer failable

* Update Sources/FoundationEssentials/Data/Data+Base64.swift

Co-authored-by: Elliot Knight <63256761+Harry-KNIGHT@users.noreply.github.com>

---------

Co-authored-by: Elliot Knight <63256761+Harry-KNIGHT@users.noreply.github.com>
2024-02-22 10:31:08 -08:00
Tony Parker
c418cf8c3b
Rebase ISO8601 formatting on top of new Gregorian Calendar implementation (#392) 2024-01-30 10:22:15 -08:00