@@ -24,7 +24,7 @@ namespace reactor {
24
24
25
25
enum class PortType { Input, Output, Delay };
26
26
27
- class BasePort : public ReactorElement , public GraphElement { // NOLINT
27
+ class BasePort : public GraphElement , public ReactorElement { // NOLINT
28
28
private:
29
29
BasePort* inward_binding_{nullptr };
30
30
std::set<BasePort*> outward_bindings_{};
@@ -40,6 +40,10 @@ private:
40
40
protected:
41
41
bool present_{false }; // NOLINT cppcoreguidelines-non-private-member-variables-in-classes
42
42
43
+ BasePort (const std::string& name, PortType type, Reactor* container)
44
+ : ReactorElement(name, match_port_enum(type), container)
45
+ , type_(type) {}
46
+
43
47
void register_dependency (Reaction* reaction, bool is_trigger) noexcept ;
44
48
void register_antidependency (Reaction* reaction) noexcept ;
45
49
virtual void cleanup () = 0;
@@ -68,9 +72,6 @@ protected:
68
72
}
69
73
70
74
public:
71
- BasePort (const std::string& name, PortType type, Reactor* container)
72
- : ReactorElement(name, match_port_enum(type), container)
73
- , type_(type) {}
74
75
~BasePort () noexcept override = default ;
75
76
76
77
void set_inward_binding (BasePort* port) noexcept { inward_binding_ = port; }
@@ -181,15 +182,15 @@ public:
181
182
Input (const std::string& name, Reactor* container)
182
183
: Port<T>(name, PortType::Input, container) {}
183
184
184
- Input (Input&&) = default ; // NOLINT(performance-noexcept-move-constructor)
185
+ Input (Input&&) noexcept = default ; // NOLINT(performance-noexcept-move-constructor)
185
186
};
186
187
187
188
template <class T > class Output : public Port <T> { // NOLINT
188
189
public:
189
190
Output (const std::string& name, Reactor* container)
190
191
: Port<T>(name, PortType::Output, container) {}
191
192
192
- Output (Output&&) = default ; // NOLINT(performance-noexcept-move-constructor)
193
+ Output (Output&&) noexcept = default ; // NOLINT(performance-noexcept-move-constructor)
193
194
};
194
195
195
196
} // namespace reactor
0 commit comments