systemc: Allow specific functions to shadow the base class method
authorNikos Nikoleris <nikos.nikoleris@arm.com>
Mon, 17 Dec 2018 15:50:04 +0000 (15:50 +0000)
committerNikos Nikoleris <nikos.nikoleris@arm.com>
Wed, 19 Dec 2018 09:00:26 +0000 (09:00 +0000)
sc_in::bind and sc_core::sc_object::print shadow their respective base
class method. This change adds the necessary declarations to inform
the compiler that this is intentional.

Change-Id: I8c6bc0f05aa568630783db63d52be90f4ea4748c
Signed-off-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/15135
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>

src/systemc/ext/channel/sc_in.hh
util/systemc/systemc_within_gem5/systemc_sc_main/sc_main.cc

index 85d089dbccf0c78415d042d57f09a9267e99d347..36547c21ec84c79cce0806cc2cd790b7f32c33e8 100644 (file)
@@ -83,6 +83,7 @@ class sc_in : public sc_port<sc_signal_in_if<T>, 1>
         _valueChangedFinder(*this, &sc_signal_in_if<T>::value_changed_event)
     {}
 
+    using sc_port<sc_signal_in_if<T>, 1>::bind;
     virtual void
     bind(const sc_signal_in_if<T> &i)
     {
index 13da38cd52ae4ec03257b20576cd57e8a1268131..5de1bcafa12f2d7fa0328898a3bfe884b737434c 100644 (file)
@@ -43,6 +43,7 @@ class Printer : public sc_core::sc_module
         SC_THREAD(print);
     }
 
+    using sc_core::sc_object::print;
     void
     print()
     {