title: which identifiers are available to lambda in constructor initializer list
body: <p>more to the point, what's wrong with this code:</p>
  
  <pre><code>#include &lt;assert.h&gt;
  #include &lt;functional&gt;
  using namespace std;
  
      template&lt; class BaseObjectId &gt;
      class Check
      {
      protected:
          Check( function&lt;bool()&gt; const f ) { assert( f() ); }
      };
  
      template&lt; int tpMinValue, int tpMaxValue &gt;
      class IntegerSubrange
          : private Check&lt; IntegerSubrange&lt; tpMinValue, tpMaxValue &gt; &gt;
      {
      private:
          int     value_;
  
      public:
          enum :int { minValue = tpMinValue, maxValue = tpMaxValue };
  
          static bool rangeContains( int const x )
          {
              return (minValue &lt;= x &amp;&amp; x &lt;= maxValue);
          }
  
          operator int() const
          {
              return value_;
          }
  
          void operator/=( int const rhs )
          {
              value_ /= rhs;
              assert( rangeContains( value_ ) );
          }
  
          explicit IntegerSubrange( int const value )
              : Check&lt; IntegerSubrange&lt; tpMinValue, tpMaxValue &gt; &gt;(
                  [=]() -&gt; bool { return rangeContains( value ); }
                  )
              , value_( value )
          {}
      };
  
  int main() {}
  </code></pre>
  
  <p>Visual C++ reports a <em>syntax error</em>:</p>
  
  <pre>
  foo.cpp
  foo.cpp(41) : error C2059: syntax error : ')'
          foo.cpp(44) : see reference to class template instantiation 'IntegerSubrange' being compiled
  foo.cpp(42) : error C2059: syntax error : ','
  foo.cpp(43) : error C2334: unexpected token(s) preceding '{'; skipping apparent function body
  </pre>