title: Displaying object name inside destructor
body: <p>Inside FileTwo.h</p>
  
  <pre><code>   #include"iostream"
      using namespace std ;
      class FileTwo{
      public:
        FileTwo(){
          cout&lt;&lt;"constructor for";//Here want to show the object for which the constructor has been called
        }
      ~Filetwo(){
        cout&lt;&lt;"Destructor for ";//Here want to show the object for which the destructor has been called 
      };
  </code></pre>
  
  <p>Inside main.cpp</p>
  
  <pre><code>#include"Filetwo.h" 
  
  int main(){
    FileTwo two ;
    return 0;
  }
  </code></pre>
  
  <p>I know this sample program is very small , so we can able to find out the object for which the constructor and destructor has been called . But for big project is there any way to know the object name ? Thanks in advance .</p>