title: Getting around the reinterpret cast limitation with constexpr
body: <p>In c++11, a <code>constexpr</code> expression cannot contain reinterpret casts. So for instance, if one wanted to manipulate the bits in a floating point number, say to find the mantissa of the number:</p>
  
  <pre><code>constexpr unsigned int mantissa(float x) { 
      return ((*(unsigned int*)&amp;x &lt;&lt; 9) &gt;&gt; 9); 
  };
  </code></pre>
  
  <p>The above code would fail to be <code>constexpr</code>.  In theory, I can't see how a reinterpret cast in this or similar cases can be any different from arithmetic operators, but the complier (and the standard) don't allow it.</p>
  
  <p>Is there any clever way of getting around this limitation? </p>