systemc: Implement the << operator for sc_signal.
authorGabe Black <gabeblack@google.com>
Thu, 30 Aug 2018 23:01:47 +0000 (16:01 -0700)
committerGabe Black <gabeblack@google.com>
Wed, 3 Oct 2018 00:26:48 +0000 (00:26 +0000)
Change-Id: I16955e58d96d49ec3bba90b73f5a368a245da438
Reviewed-on: https://gem5-review.googlesource.com/c/12454
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>

src/systemc/ext/channel/sc_signal.hh

index d195f4d568370f08830df9349125c875cbb8ac1b..022bd339494f7436e38e2b92c7963de0279770dc 100644 (file)
@@ -173,9 +173,9 @@ class sc_signal : public sc_signal_inout_if<T>,
 
 template <class T, sc_writer_policy WRITER_POLICY>
 inline std::ostream &
-operator << (std::ostream &os, const sc_signal<T, WRITER_POLICY> &)
+operator << (std::ostream &os, const sc_signal<T, WRITER_POLICY> &s)
 {
-    sc_channel_warn_unimpl(__PRETTY_FUNCTION__);
+    os << s.read();
     return os;
 }