message & friends: make formattable

So we can easily debug-print them.
This commit is contained in:
Dirk-Jan C. Binnema
2023-08-09 20:06:03 +03:00
parent 4dcd457b7f
commit 04219b55f7
4 changed files with 38 additions and 9 deletions

View File

@ -460,15 +460,10 @@ private:
}; // Message
MU_ENABLE_BITOPS(Message::Options);
static inline std::ostream&
operator<<(std::ostream& os, const Message& msg)
{
os << msg.sexp();
return os;
static inline auto
format_as(const Message& msg) {
return msg.path();
}
} // Mu
#endif /* MU_MESSAGE_HH__ */