Skip to content

Commit d20d972

Browse files
committed
Cleanup.
1 parent 39b1051 commit d20d972

1 file changed

Lines changed: 15 additions & 3 deletions

File tree

include/react/Domain.h

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,19 +96,19 @@ class TransactionStatus
9696
using PtrT = REACT_IMPL::WaitingStatePtrT;
9797

9898
public:
99+
// Default ctor
99100
inline TransactionStatus() :
100101
statePtr_( StateT::Create() )
101102
{}
102103

103-
TransactionStatus(const TransactionStatus&) = delete;
104-
TransactionStatus& operator=(const TransactionStatus&) = delete;
105-
104+
// Move ctor
106105
inline TransactionStatus(TransactionStatus&& other) :
107106
statePtr_( std::move(other.statePtr_) )
108107
{
109108
other.statePtr_ = StateT::Create();
110109
}
111110

111+
// Move assignment
112112
inline TransactionStatus& operator=(TransactionStatus&& other)
113113
{
114114
if (this != &other)
@@ -119,6 +119,10 @@ class TransactionStatus
119119
return *this;
120120
}
121121

122+
// Deleted copy ctor & assignment
123+
TransactionStatus(const TransactionStatus&) = delete;
124+
TransactionStatus& operator=(const TransactionStatus&) = delete;
125+
122126
inline void Wait()
123127
{
124128
assert(statePtr_.Get() != nullptr);
@@ -152,21 +156,29 @@ class Continuation : public REACT_IMPL::ContinuationBase<D,D2>
152156
using SourceDomainT = D;
153157
using TargetDomainT = D2;
154158

159+
// Default ctor
155160
Continuation() = default;
156161

162+
// Move ctor
157163
Continuation(Continuation&& other) :
158164
Continuation::ContinuationBase( std::move(other) )
159165
{}
160166

167+
// Node ctor
161168
explicit Continuation(NodePtrT&& nodePtr) :
162169
Continuation::ContinuationBase( std::move(nodePtr) )
163170
{}
164171

172+
// Move assignment
165173
Continuation& operator=(Continuation&& other)
166174
{
167175
Continuation::ContinuationBase::operator=( std::move(other) );
168176
return *this;
169177
}
178+
179+
// Deleted copy ctor & assignment
180+
Continuation(const Continuation&) = delete;
181+
Continuation& operator=(const Continuation&) = delete;
170182
};
171183

172184
///////////////////////////////////////////////////////////////////////////////////////////////////

0 commit comments

Comments
 (0)