JH-Toolkit v1.4.1
An engineering-oriented C++20 toolkit with duck-typed concepts, static design, async coroutines, and semantic containers — header-only, RTTI-free, and concurrency-friendly.
Loading...
Searching...
No Matches
jh::pod::streamable Concept Reference

Checks whether a type can be streamed to std::ostream. More...

#include <jh/pods/stringify.h>

Concept definition

template<typename T>
concept streamable = requires(std::ostream &os, const T &value) {
{ os << value } -> std::same_as<std::ostream &>;
}
Checks whether a type can be streamed to std::ostream.
Definition stringify.h:142

Detailed Description

Checks whether a type can be streamed to std::ostream.

Evaluates whether os << value is a valid expression producing std::ostream&.

Note
This concept relies on ADL. Users may override or extend streamability by providing their own operator<<.
Warning
Intended for debugging and inspection only. Not a guarantee of production-grade output.