title: How to make a pointer struct member behave like an array?
body: <p>I have a pointer in my struct.</p>
  <pre><code>typedef struct AnotherStructure
  {
      int member1;
  } AnotherStructure;
  
  typedef struct Structure
  {
      int member1;
      AnotherStructure* member2;
  } Structure;
  
  AnotherStructure x = {0};
  </code></pre>
  <p>This pointer should not behave like a normal pointer but instead should behave like an array. Now I have another piece of code,</p>
  <pre><code>Structure some_struct = {10, {&amp;x, NULL /* Sentinel */}};
  </code></pre>
  <p>This doesn't work. I know why. It's because it's trying to initialize a pointer but fails to do so because the first element is neither a pointer nor an address and because we're providing it multiple initializers. But I also tried,</p>
  <pre><code>AnotherStructure* array[] = {&amp;x, NULL};
  Structure some_struct = {10, array};
  </code></pre>
  <p>This also doesn't work because there are different indirections (<code>AnotherStructure**</code> to <code>AnotherStructure*</code>).</p>
  <p>Now I can't actually change the main structure. What I can do is provide different inputs to the Structure initialization. Is there way to do that?</p>