diff options
Diffstat (limited to 'src/uio.hh')
| -rw-r--r-- | src/uio.hh | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -1,7 +1,7 @@ #ifndef UIO_HH #define UIO_HH -#include "io.hh" // IWYU pragma: export +#include "io.hh" // IWYU pragma: export #include <cstddef> #include <expected> @@ -25,7 +25,7 @@ struct ReaderConfig { bool skip_bom{true}; }; -} // namespace u8 +} // namespace u namespace u8 { @@ -34,15 +34,15 @@ class Reader : public io::Reader { using io::Reader::read; using io::Reader::repeat_read; - [[nodiscard]] std::expected<size_t, io::ReadError> read( - std::string& data, size_t max); + [[nodiscard]] std::expected<size_t, io::ReadError> read(std::string& data, + size_t max); [[nodiscard]] std::expected<size_t, io::ReadError> repeat_read( std::string& data, size_t max); }; -[[nodiscard]] std::unique_ptr<Reader> open( - std::unique_ptr<io::Reader> reader, u::ReaderConfig config = {}); +[[nodiscard]] std::unique_ptr<Reader> open(std::unique_ptr<io::Reader> reader, + u::ReaderConfig config = {}); [[nodiscard]] std::expected<std::unique_ptr<Reader>, io::OpenError> open( const std::string& file_path, u::ReaderConfig config = {}); @@ -58,15 +58,15 @@ class Reader : public io::Reader { using io::Reader::read; using io::Reader::repeat_read; - [[nodiscard]] std::expected<size_t, io::ReadError> read( - std::u16string& data, size_t max); + [[nodiscard]] std::expected<size_t, io::ReadError> read(std::u16string& data, + size_t max); [[nodiscard]] std::expected<size_t, io::ReadError> repeat_read( std::u16string& data, size_t max); }; -[[nodiscard]] std::unique_ptr<Reader> open( - std::unique_ptr<io::Reader> reader, u::ReaderConfig config = {}); +[[nodiscard]] std::unique_ptr<Reader> open(std::unique_ptr<io::Reader> reader, + u::ReaderConfig config = {}); [[nodiscard]] std::expected<std::unique_ptr<Reader>, io::OpenError> open( const std::string& file_path, u::ReaderConfig config = {}); |
