From 32b4443ba2ec5c3f7c09221ab9b21911a3126ef9 Mon Sep 17 00:00:00 2001 From: Lexi Winter Date: Mon, 23 Jun 2025 18:34:18 +0100 Subject: add separate module implementation files --- nihil.ucl/emit.cc | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 nihil.ucl/emit.cc (limited to 'nihil.ucl/emit.cc') diff --git a/nihil.ucl/emit.cc b/nihil.ucl/emit.cc new file mode 100644 index 0000000..480ddd8 --- /dev/null +++ b/nihil.ucl/emit.cc @@ -0,0 +1,21 @@ +/* + * This source code is released into the public domain. + */ + +module; + +#include +#include + +module nihil.ucl; + +namespace nihil::ucl { + +auto operator<<(std::ostream &stream, object const &o) +-> std::ostream & +{ + emit(o, emitter::json, std::ostream_iterator(stream)); + return stream; +} + +} // namespace nihil::ucl -- cgit v1.2.3