v0.3.0
Major Changes
- Support Aarch64
- Support musl
- Add https support (not yet for websockets)
- Dockerfile based builds
- Support some async file I/O a la rust's tokio
- Add async mutex
Breaking Changes
None
The most exciting feature addition is the async file I/O, which emulates rust's tokio's async functions:
// enqueue reading the file on another thread and co_await its result
// not using auto to show the type in example. Using auto would be a lot easier here.
tl::expected<std::string, Ichor::FileIOError> ret = co_await async_io_svc->read_whole_file("AsyncFileIO.txt");
if(!ret || ret != "This is a test") {
fmt::print("Couldn't read file\n");
co_return {};
}
// enqueue writing to file (automatically overwrites if already exists)
tl::expected<void, Ichor::FileIOError> ret2 = co_await async_io_svc->write_file("AsyncFileIO.txt", "Overwrite");
if(!ret2) {
fmt::print("Couldn't write file\n");
co_return {};
}
ret = co_await async_io_svc->read_whole_file("AsyncFileIO.txt");
if(!ret || ret != "Overwrite") {
fmt::print("Couldn't read file\n");
co_return {};
}
More information on the async I/O can be found in the docs.
Full Changelog: v0.2.0...v0.3.0