title: Is the result of static_casting a constexpr void* a constant expression?
body: <p>clang is rejecting this code which gcc allows:</p>
  
  <pre><code>int main() {
      static constexpr const void *vp = nullptr;
      static constexpr const char *cp = static_cast&lt;const char*&gt;(vp);
  }
  </code></pre>
  
  <p>With the following:</p>
  
  <pre><code>error: constexpr variable 'cp' must be initialized by a constant expression
    static constexpr const char *cp = static_cast&lt;const char*&gt;(vp);
  </code></pre>
  
  <p>After reading the final listing in <a href="https://isocpp.org/files/papers/N3797.pdf" rel="nofollow">N3797</a> 5.9/2 I don't see anything that forbids <code>static_cast</code>'s use in a constant expression.  Am I looking in the wrong place or misreading something? Or should I open a bug against clang?</p>