summaryrefslogtreecommitdiff
path: root/src/systemc/ext
diff options
context:
space:
mode:
authorGabe Black <gabeblack@google.com>2018-07-20 19:25:48 -0700
committerGabe Black <gabeblack@google.com>2018-09-11 21:45:15 +0000
commita91caa594bcc4691c5d18e400a773e082c71d240 (patch)
tree0b5b8d670da05899c512df4e15e1e6fb6f1898d4 /src/systemc/ext
parentca3b0eb1559138f0762dd39581ea64851baf742f (diff)
downloadgem5-a91caa594bcc4691c5d18e400a773e082c71d240.tar.xz
systemc: Promote some functions to sc_export_base.
There are a few functions which return a generic sc_interface pointer which were (in the spec) defined to be in the interface type specific sc_export class. They don't need to be and aren't in the Accellera implementation, and without having them in the base class there's no good way to get at a generic interface pointer from an export. Change-Id: Iba692c79bf1d4f7684f28447d8b22c88ef4b804d Reviewed-on: https://gem5-review.googlesource.com/12043 Reviewed-by: Gabe Black <gabeblack@google.com> Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src/systemc/ext')
-rw-r--r--src/systemc/ext/core/sc_export.hh11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/systemc/ext/core/sc_export.hh b/src/systemc/ext/core/sc_export.hh
index dc2176492..421e063c0 100644
--- a/src/systemc/ext/core/sc_export.hh
+++ b/src/systemc/ext/core/sc_export.hh
@@ -41,6 +41,9 @@ class sc_export_base : public sc_object
{
public:
void warn_unimpl(const char *func) const;
+
+ virtual sc_interface *get_iterface() = 0;
+ virtual const sc_interface *get_interface() const = 0;
};
template <class IF>
@@ -71,14 +74,14 @@ class sc_export : public sc_export_base
return nullptr;
}
- virtual sc_interface *
- get_iterface()
+ sc_interface *
+ get_iterface() override
{
warn_unimpl(__PRETTY_FUNCTION__);
return nullptr;
}
- virtual const sc_interface *
- get_interface() const
+ const sc_interface *
+ get_interface() const override
{
warn_unimpl(__PRETTY_FUNCTION__);
return nullptr;