fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. class Ca
  5.  
  6. {
  7. public:
  8.  
  9. Ca() {printf("\nCONST this = %p\n",(void *)this);}
  10. ~Ca() {printf("\n DEST this = %p\n",(void *)this);}
  11. Ca(const Ca &pCopy){printf("\nCOPY this = %p\n",(void *)&pCopy);}
  12. void operator=(Ca pCopy){printf("\nOP= this = %p\n",(void *)&pCopy);}
  13. };
  14.  
  15. void hgh(Ca v);
  16.  
  17. int main()
  18.  
  19. {
  20. hgh(Ca());
  21. return 0;
  22. }
  23.  
  24. void hgh(Ca v)
  25.  
  26. {
  27. printf("\nhgh() = %p\n",(void *)&v);
  28. }
Success #stdin #stdout 0s 3456KB
stdin
Standard input is empty
stdout
CONST this = 0xbff580af

hgh() = 0xbff580af

 DEST this = 0xbff580af