Data Structures | |
| struct | lib::format::dec |
| Integer with padding options. More... | |
| struct | lib::format::format_context |
| Internal buffer management for formatting. More... | |
| struct | lib::format::formatter< T > |
| Default formatter implementation for various types. More... | |
| struct | lib::format::formatter< bool > |
| Formatter for booleans — prints "true" or "false". More... | |
| struct | lib::format::formatter< char > |
| Formatter for characters. More... | |
| struct | lib::format::formatter< char[N]> |
| Formatter for fixed-size character arrays (string literals). More... | |
| struct | lib::format::formatter< const char * > |
| Formatter for C-style strings. More... | |
| struct | lib::format::formatter< dec > |
| struct | lib::format::formatter< hex > |
| struct | lib::format::formatter< std::source_location > |
| Formatter for std::pair. More... | |
| struct | lib::format::formatter< std::span< T, Extent > > |
| Formatter for std::span<T, Extent>. More... | |
| struct | lib::format::formatter< std::string_view > |
| Formatter for string views. More... | |
| struct | lib::format::formatter< T * > |
| Formatter for pointers. More... | |
| struct | lib::format::formatter< T > |
| Base formatter for integers. More... | |
| struct | lib::format::formatter< uchar[N]> |
| Formatter for fixed-size byte (uchar) arrays. More... | |
| struct | lib::format::hex |
| Hexadecimal wrapper for integers. More... | |
Functions | |
| auto | format (format_context &ctx, const T &val) const noexcept -> void |
| auto | format (format_context &ctx, bool val) const noexcept -> void |
| auto | format (format_context &ctx, char val) const noexcept -> void |
| auto | format (format_context &ctx, const char(&val)[N]) const noexcept -> void |
| auto | format (format_context &ctx, const char *val) const noexcept -> void |
| auto | format (format_context &ctx, dec d) const noexcept -> void |
| auto | format (format_context &ctx, hex h) const noexcept -> void |
| auto | format (format_context &ctx, const std::source_location &val) const noexcept -> void |
| Format the expected into ctx. | |
| auto | format (format_context &ctx, const std::span< T, Extent > &val) const noexcept -> void |
| Format the span into ctx. | |
| auto | format (format_context &ctx, std::string_view val) const noexcept -> void |
| auto | format (format_context &ctx, T *val) const noexcept -> void |
| auto | format (format_context &ctx, T val) const noexcept -> void |
| auto | format (format_context &ctx, const uchar(&val)[N]) const noexcept -> void |
| template<typename... Args> | |
| auto | lib::format::format_to (std::span< char > buf, std::string_view fmt, Args &&... args) -> usize |
| Entry point for formatting. | |
| auto | write (char c) noexcept -> void |
| auto | write (std::string_view s) noexcept -> void |
Variables | |
| std::span< char > | buffer |
| usize | offset {0} |
| bool | pad_zero {false} |
| bool | pad_zero {false} |
| u64 | value |
| u64 | value |
| usize | width {0} |
| usize | width {0} |
Files | |
| file | lib/format.cxxm |
| Type-safe minimal formatter for kernel usage. | |