title: How to use make_tuple() in static constexpr class member?
body: <p>I am trying to use <code>make_tuple()</code> in <code>constexpr</code>. It works in global scope. But it generates link error for <code>static constexpr</code> class member.</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;tuple&gt;
  
  using namespace std;
  
  class A
  {
  public:
      static constexpr auto z = make_tuple(5, 3.0);
  };
  
  constexpr auto tp = make_tuple(6, 3.2);
  
  int main()
  {
  
      cout &lt;&lt; get&lt;0&gt;(tp) &lt;&lt; " " &lt;&lt; get&lt;1&gt;(tp) &lt;&lt; endl; // OK
  
      cout &lt;&lt; get&lt;0&gt;(A::z) &lt;&lt; "  " &lt;&lt; get&lt;1&gt;(A::z) &lt;&lt; endl; // error: (.text+0x5a): undefined reference to `A::z'
                                                            //        (.text+0x67): undefined reference to `A::z'
  
  }
  </code></pre>
  
  <p>I have checked <a href="http://en.cppreference.com/w/cpp/utility/tuple/make_tuple" rel="nofollow noreferrer">here</a> <code>make_tuple</code> is not itself a <code>constexpr</code> in <code>c++11</code>. I guess that is not the problem in this case. If it was it would generate a compile error instead of link error.</p>
  
  <p>I have tried to define the <code>constexpr</code> outside the class like bellow as suggested by <a href="https://stackoverflow.com/a/35930465/1992776">this answer</a></p>
  
  <pre><code>class A
  {
  public:
      static constexpr tuple&lt;int, double&gt; z;
  };
  
  constexpr tuple&lt;int, double&gt; A::z = make_tuple(5, 3.0);
  </code></pre>
  
  <p>But, it generates several compile error. That makes sanse according to answers of <a href="https://stackoverflow.com/questions/11522399/constexpr-initializing-static-member-using-static-function">constexpr initializing static member using static function</a></p>
  
  <p>What is the correct way to use <code>make_tuple</code> in <code>static constexpr</code> class member?</p>
  
  <p>Compiler:
  <code>g++ 4.8.4</code> and <code>clang 3.4</code> with <code>-std=c++11</code></p>