title: c++ class members and delayed initialization
body: <p>I am currently looking into new <code>c++11</code> <code>random</code> library. For simplification, I created following class</p>
  
  <pre><code>class my_rand {
      private:
          std::mt19937_64 eng;
      public:
          my_rand() {
              std::array&lt;int, std::mt19937::state_size&gt; seed_data;
              std::random_device rd;
              std::generate_n(seed_data.data(), seed_data.size(), std::ref(rd));
              std::seed_seq seq(std::begin(seed_data), std::end(seed_data));
              this-&gt;eng.seed(seq);
          };
          unsigned long long operator() () {
              return this-&gt;eng();
          };
  };
  </code></pre>
  
  <p>so that I can just do <code>my_rand rand;</code> once and then repeatedly call <code>rand()</code> to generate random numbers.</p>
  
  <p>However, now I want to use <code>std::uniform_int_distribution</code> to set bound to numbers I get. It seams obvious to specify bounds while creating the object, so that invocations stay the same. The problem is, if I add private member (something like <code>std::uniform_int_distribution&lt;long long&gt; uid;</code>) then later in constructor I will not be able to set bounds because <code>uid</code> will already be initialized. I could not find method of <code>std::uniform_int_distribution</code> which allowed to set limits after it is created.</p>
  
  <p>I may well be missing some point here, so thanks in advance for any help.</p>