title: Constexpr placement new?
body: <p>The C++ standard specifically bans calling <code>new</code> in a constant expression (N4296 section 5.20 [expr.const]):</p>
  <blockquote>
  <p>A conditional-expression e is a core constant expression unless the evaluation of e, following the rules of the abstract machine (1.9), would evaluate one of the following expressions:</p>
  <p>...</p>
  <p>— a new-expression (5.3.4);</p>
  </blockquote>
  <p>This ban (as far as I can see) extends to <em>all</em> forms of <code>new</code>, including placement new. However, since placement new doesn't actually allocate any memory and merely runs constructors at the given location, and since it's legal to take the address of a variable in a <code>constexpr</code> context (indeed, <code>std::addressof</code> will be constexpr in C++17), it seems to me that this prohibition could (in principle at least) be eased to allow placement new in constexpr functions.</p>
  <p>So my question is, am I missing something? Is there a good reason why placement new is forbidden in <code>constexpr</code> functions?</p>
  <p>(For context: the current rules pretty much require that constexpr-enabled sum types like <code>std::variant</code> are implemented as a recursive union. It would be nicer to be able to use something like <code>std::aligned_storage</code> and placement new, but currently that's not possible.)</p>