Mercurial > octave
comparison liboctave/array/Array.h @ 29946:3e5e88d9c85f
tag ArrayRep copy assignment operator with =delete
* Array.h (ArrayRep::operator= (const ArrayRep&)): Tag with =delete
instead of declaring it private and leaving it undefined.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Fri, 06 Aug 2021 11:19:28 -0400 |
parents | da7210e30f3e |
children | f254c302bb9c |
comparison
equal
deleted
inserted
replaced
29945:13e9e244284e | 29946:3e5e88d9c85f |
---|---|
175 | 175 |
176 ~ArrayRep (void) { delete [] m_data; } | 176 ~ArrayRep (void) { delete [] m_data; } |
177 | 177 |
178 octave_idx_type numel (void) const { return m_len; } | 178 octave_idx_type numel (void) const { return m_len; } |
179 | 179 |
180 private: | |
181 | |
182 // No assignment! | 180 // No assignment! |
183 | 181 |
184 OCTARRAY_API ArrayRep& operator = (const ArrayRep& a); | 182 ArrayRep& operator = (const ArrayRep&) = delete; |
185 }; | 183 }; |
186 | 184 |
187 //-------------------------------------------------------------------- | 185 //-------------------------------------------------------------------- |
188 | 186 |
189 public: | 187 public: |