U++ framework
Do not panic. Ask here before giving up.

Home » Community » Coffee corner » How would you design a good copy/move semantics system?
Re: How would you design a good copy/move semantics system? [message #44145 is a reply to message #44057] Wed, 07 January 2015 11:31 Go to previous messageGo to previous message
cbpporter is currently offline  cbpporter
Messages: 1428
Registered: September 2007
Ultimate Contributor
Hi Lance,

Back from my holidays so Happy New Year to you and everyone else here!

Quote:

CMD(CMD&& c):CM(std::move(c))


I have very little practical experience with C++11 so I did not know that you need to explicitly call the move constructor as such when using inheritance.

What I'm trying to obtain is basically a single rule/library wide convention relating to move, without C++11 features. Things become more complicated when assignment operators are added and also when the code gets optimized, with some assignments not having code generated for them.

Not sure yet if one convention is enough to cover all cases. Furthermore, not sure if there are some implementation constrains related to C++ in order to maximize implicit call of move when returning values.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Extracting links challenge
Next Topic: Banana PI
Goto Forum:
  


Current Time: Fri May 01 09:30:26 GMT+2 2026

Total time taken to generate the page: 0.00642 seconds