Skip to content

Commit

Permalink
console: Added several missing default constructors and opertors for …
Browse files Browse the repository at this point in the history
…asHex_t
  • Loading branch information
dragonmux committed Aug 21, 2023
1 parent e01203a commit ad9c040
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions substrate/console
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,13 @@ namespace substrate
constexpr asHex_t(const T value) noexcept : maxDigits{sizeof(T) * 2},
msbShift{uint8_t(4U * (maxDigits - 1U))}, _value(value) { }

SUBSTRATE_NOINLINE
void operator ()(const consoleStream_t &stream) const noexcept final
constexpr asHex_t(const asHex_t &) noexcept = default;
constexpr asHex_t(asHex_t &&) noexcept = default;
~asHex_t() noexcept = default;
constexpr asHex_t &operator =(const asHex_t &) noexcept = default;
constexpr asHex_t &operator =(asHex_t &&) noexcept = default;

SUBSTRATE_NOINLINE void operator ()(const consoleStream_t &stream) const noexcept final
{
uintmax_t value{_value};
// If we've been asked to pad by more than the maximum possible length of the number
Expand Down

0 comments on commit ad9c040

Please sign in to comment.