title: Getting name and type of a struct field from its object
body: <p>For example, I have a struct which is something like this:</p>
  
  <pre><code>struct Test
  {
      int i;
      float f;
      char ch[10];
  };
  </code></pre>
  
  <p>And I have an object of this struct such as:</p>
  
  <pre><code>Test obj;
  </code></pre>
  
  <p>Now, I want to programmatically get the field names and type of <code>obj</code>. Is it possible?</p>
  
  <p>This is C++ BTW.</p>