-
Jonathan Wakely authored
Hui Xie pointed out that we don't need a dummy member in the union, because all constructors always initialize either _M_val or _M_unex. We still need the _M_void member of the expected<void, E> specialization, because the constructor has to initialize something when not using the _M_unex member. libstdc++-v3/ChangeLog: * include/std/expected (expected::_M_invalid): Remove.
Jonathan Wakely authoredHui Xie pointed out that we don't need a dummy member in the union, because all constructors always initialize either _M_val or _M_unex. We still need the _M_void member of the expected<void, E> specialization, because the constructor has to initialize something when not using the _M_unex member. libstdc++-v3/ChangeLog: * include/std/expected (expected::_M_invalid): Remove.