title: initialize boost::multi_array in a class
body: <p>For start I would like to say that I am newbie.</p>
  
  <p>I am trying to initialized <code>boost:multi_array</code> inside my class. I know how to create a <code>boost:multi_array</code>:</p>
  
  <pre><code>boost::multi_array&lt;int,1&gt; foo ( boost::extents[1000] );
  </code></pre>
  
  <p>but as part of a class I have problems:</p>
  
  <pre><code>class Influx {
      public:
      Influx ( uint32_t num_elements );
      boost::multi_array&lt;int,1&gt; foo;
  
  private:
  
  };
  
  Influx::Influx ( uint32_t num_elements ) {
      foo = boost::multi_array&lt;int,1&gt; ( boost::extents[ num_elements ] );
  }
  </code></pre>
  
  <p>My program passes through compilation but during run-time I get an error when I try to accuse an element from <code>foo</code> (e.g. <code>foo[0]</code>).</p>
  
  <p>How to solve this problem?</p>