Click here to Skip to main content
15,900,907 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 2:34
George_George8-Jan-08 2:34 
GeneralRe: using swap to make assignment operator exception safe Pin
CPallini8-Jan-08 3:14
mveCPallini8-Jan-08 3:14 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:18
George_George8-Jan-08 3:18 
GeneralRe: using swap to make assignment operator exception safe Pin
CPallini8-Jan-08 3:30
mveCPallini8-Jan-08 3:30 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:33
George_George8-Jan-08 3:33 
GeneralYou're welcome Pin
CPallini8-Jan-08 3:36
mveCPallini8-Jan-08 3:36 
GeneralRe: using swap to make assignment operator exception safe Pin
toxcct8-Jan-08 2:03
toxcct8-Jan-08 2:03 
GeneralRe: using swap to make assignment operator exception safe Pin
CPallini8-Jan-08 2:12
mveCPallini8-Jan-08 2:12 
Well, even ignoring the recursion madness of George sample code, I think that swap may take care about, since it will perhaps be coded in a way similar to the following:
A temp;
temp = a;
a = *this;
*this = temp;


Smile | :)

If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.

[my articles]


GeneralRe: using swap to make assignment operator exception safe Pin
toxcct8-Jan-08 2:17
toxcct8-Jan-08 2:17 
GeneralRe: using swap to make assignment operator exception safe Pin
CPallini8-Jan-08 2:29
mveCPallini8-Jan-08 2:29 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:15
George_George8-Jan-08 3:15 
GeneralRe: using swap to make assignment operator exception safe Pin
CPallini8-Jan-08 3:21
mveCPallini8-Jan-08 3:21 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:27
George_George8-Jan-08 3:27 
GeneralRe: using swap to make assignment operator exception safe Pin
toxcct8-Jan-08 3:35
toxcct8-Jan-08 3:35 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:40
George_George8-Jan-08 3:40 
JokeRe: using swap to make assignment operator exception safe Pin
CPallini8-Jan-08 3:54
mveCPallini8-Jan-08 3:54 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:06
George_George8-Jan-08 3:06 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:16
George_George8-Jan-08 3:16 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 2:33
George_George8-Jan-08 2:33 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 2:30
George_George8-Jan-08 2:30 
GeneralRe: using swap to make assignment operator exception safe Pin
toxcct8-Jan-08 2:37
toxcct8-Jan-08 2:37 
GeneralRe: using swap to make assignment operator exception safe Pin
George_George8-Jan-08 3:13
George_George8-Jan-08 3:13 
GeneralStrange error ! Pin
CrocodileBuck8-Jan-08 0:26
CrocodileBuck8-Jan-08 0:26 
GeneralRe: Strange error ! Pin
CPallini8-Jan-08 0:39
mveCPallini8-Jan-08 0:39 
GeneralRe: Strange error ! Pin
CrocodileBuck8-Jan-08 0:54
CrocodileBuck8-Jan-08 0:54 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.