See previous commit
This commit is contained in:
@@ -34,7 +34,7 @@ namespace LXC::Util
|
|||||||
namespace LXC::Internal
|
namespace LXC::Internal
|
||||||
{
|
{
|
||||||
// Checks if a type can be outputted to std::ostream //
|
// Checks if a type can be outputted to std::ostream //
|
||||||
template<typename T> concept Logable = requires(std::ostream& os, T t)
|
template<typename T> concept Logable = requires(std::ostream & os, T t)
|
||||||
{
|
{
|
||||||
// I have no idea what this part does at all //
|
// I have no idea what this part does at all //
|
||||||
{ os << t } -> std::same_as<std::ostream&>;
|
{ os << t } -> std::same_as<std::ostream&>;
|
||||||
@@ -62,7 +62,7 @@ namespace LXC::Internal
|
|||||||
inline void WriteImpl(std::ostream& os, Args&&... args)
|
inline void WriteImpl(std::ostream& os, Args&&... args)
|
||||||
{
|
{
|
||||||
static HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
|
static HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
|
||||||
if constexpr(col != Util::Color::DEFAULT)
|
if constexpr (col != Util::Color::DEFAULT)
|
||||||
SetConsoleTextAttribute(hConsole, static_cast<WORD>(col));
|
SetConsoleTextAttribute(hConsole, static_cast<WORD>(col));
|
||||||
|
|
||||||
(os << ... << std::forward<Args>(args));
|
(os << ... << std::forward<Args>(args));
|
||||||
|
|||||||
Reference in New Issue
Block a user