diff options
author | Gabe Black <gabeblack@google.com> | 2018-10-03 16:16:08 -0700 |
---|---|---|
committer | Gabe Black <gabeblack@google.com> | 2018-10-16 00:49:23 +0000 |
commit | d45caee43e10c50d837aadc56b385f6340366cae (patch) | |
tree | 5e52e31935240f0e00af59e6407b282448c00233 /src | |
parent | 9cd313edf5ab8ca24d80545cd7235c9b19932589 (diff) | |
download | gem5-d45caee43e10c50d837aadc56b385f6340366cae.tar.xz |
systemc: Add an sc_gem5::Port destructor.
This destructor just removes the port from the list of all ports.
Change-Id: I809b529540c2946d20aeb8d64467d77dc94a7a96
Reviewed-on: https://gem5-review.googlesource.com/c/13288
Reviewed-by: Gabe Black <gabeblack@google.com>
Maintainer: Gabe Black <gabeblack@google.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/systemc/core/port.hh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/systemc/core/port.hh b/src/systemc/core/port.hh index 8c09ad0d3..f7b1bbce4 100644 --- a/src/systemc/core/port.hh +++ b/src/systemc/core/port.hh @@ -147,6 +147,8 @@ class Port allPorts.push_front(this); } + ~Port() { allPorts.remove(this); } + void bind(::sc_core::sc_interface *interface) { |