aboutsummaryrefslogtreecommitdiffstats
path: root/nihil.util/capture_stream.ccm
diff options
context:
space:
mode:
authorLexi Winter <lexi@le-fay.org>2025-07-01 17:07:04 +0100
committerLexi Winter <lexi@le-fay.org>2025-07-01 17:07:04 +0100
commit2e2d1bd3b6c7776b77c33b94f30ead89367a71e6 (patch)
tree54d37ffadf8e677938d9b7a28e4e9b71be1e75c1 /nihil.util/capture_stream.ccm
parent36427c0966faa7aecd586b397ed9b845f18172f5 (diff)
downloadnihil-2e2d1bd3b6c7776b77c33b94f30ead89367a71e6.tar.gz
nihil-2e2d1bd3b6c7776b77c33b94f30ead89367a71e6.tar.bz2
add nihil.std
Diffstat (limited to 'nihil.util/capture_stream.ccm')
-rw-r--r--nihil.util/capture_stream.ccm19
1 files changed, 6 insertions, 13 deletions
diff --git a/nihil.util/capture_stream.ccm b/nihil.util/capture_stream.ccm
index 7ec39a9..f061558 100644
--- a/nihil.util/capture_stream.ccm
+++ b/nihil.util/capture_stream.ccm
@@ -1,20 +1,13 @@
-/*
- * This source code is released into the public domain.
- */
-
-module;
-
-#include <iostream>
-
+// This source code is released into the public domain.
export module nihil.util:capture_stream;
+import nihil.std;
+
namespace nihil {
-/*
- * Capture output written to a stream and redirect it to an internal string
- * buffer. Call .str() to get the data written. Call .release() to stop
- * capturing (or simply delete the capture_stream object).
- */
+// Capture output written to a stream and redirect it to an internal string
+// buffer. Call .str() to get the data written. Call .release() to stop
+// capturing (or simply delete the capture_stream object).
export template<typename Char, typename Traits>
struct capture_stream {
capture_stream(std::basic_ostream<Char, Traits> &stream)