std::bit_cast with std::array : <p>In his recent talk <a href="https://www.youtube.com/watch?v=_qzMpk-22cc" rel="noreferrer">“Type punning in modern C++”</a> Timur Doumler <a href="https://youtu.be/_qzMpk-22cc?t=2755" rel="noreferrer">said</a> that <code>std::bit_cast</code> cannot be used to bit cast a <code>float</code> into an <code>unsigned char[4]</code> because C-style arrays cannot be returned from a function. We should either use <code>std::memcpy</code> or wait until C++23 (or later) when something like <code>reinterpret_cast&lt;unsigned char*&gt;(&amp;f)[i]</code> will become well defined.</p>

<p>In C++20, can we use an <code>std::array</code> with <code>std::bit_cast</code>,</p>

<pre><code>float f = /* some value */;
auto bits = std::bit_cast&lt;std::array&lt;unsigned char, sizeof(float)&gt;&gt;(f);
</code></pre>

<p>instead of a C-style array to get bytes of a <code>float</code>?</p>
