std::optional is relatively new, and supports dereferencing, which when it’s empty is UB instead of an abort.
There are no plans to add checks to any existing APIs, because “it didn’t have a branch before” is also considered a compatibility issue.
std::optional is relatively new, and supports dereferencing, which when it’s empty is UB instead of an abort.
There are no plans to add checks to any existing APIs, because “it didn’t have a branch before” is also considered a compatibility issue.