diff options
| author | Joel Klinghed <the_jk@spawned.biz> | 2025-09-15 21:15:53 +0200 |
|---|---|---|
| committer | Joel Klinghed <the_jk@spawned.biz> | 2025-09-15 21:15:53 +0200 |
| commit | aa49abdf239bae6065fddd0839ec67a404c9748c (patch) | |
| tree | 631fbb2df58aa35df3d60c65c037ef74b1807114 /src/uio.hh | |
| parent | bf41a601fd0447bcf3a2937a595a1cd8ca5c1633 (diff) | |
Add .clang-format
Make it easier to keep a consistent style
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 = {}); |
