C26497, you can mark this thing as constexpr.
This commit is contained in:
parent
93aa9455e2
commit
ae25a32913
|
@ -28,7 +28,7 @@ namespace Microsoft::Console::Utils
|
|||
void InitializeCampbellColorTableForConhost(const gsl::span<COLORREF> table);
|
||||
void SwapANSIColorOrderForConhost(const gsl::span<COLORREF> table);
|
||||
void Initialize256ColorTable(const gsl::span<COLORREF> table);
|
||||
void SetColorTableAlpha(const gsl::span<COLORREF> table, const BYTE newAlpha) noexcept;
|
||||
constexpr void SetColorTableAlpha(const gsl::span<COLORREF> table, const BYTE newAlpha) noexcept;
|
||||
|
||||
constexpr uint16_t EndianSwap(uint16_t value)
|
||||
{
|
||||
|
|
|
@ -454,7 +454,7 @@ void Utils::Initialize256ColorTable(const gsl::span<COLORREF> table)
|
|||
// - newAlpha: the new value to use as the alpha for all the entries in that table.
|
||||
// Return Value:
|
||||
// - <none>
|
||||
void Utils::SetColorTableAlpha(const gsl::span<COLORREF> table, const BYTE newAlpha) noexcept
|
||||
constexpr void Utils::SetColorTableAlpha(const gsl::span<COLORREF> table, const BYTE newAlpha) noexcept
|
||||
{
|
||||
const auto shiftedAlpha = newAlpha << 24;
|
||||
for (auto& color : table)
|
||||
|
|
Loading…
Reference in a new issue