Documentation/SmartPointers.md mentions make<>()
, adopt_own()
, adopt_own_if_nonnull()
, make_ref_counted<>()
, tadopt_ref()
, adopt_ref_if_nonnull<>()
, but it does not mention adopt_nonnull_own_or_enomem
noradopt_nonnull_ref_or_enomem()
.
(It does mention try_make<>()
and try_make_ref_counted<>()
, which wrap the _or_enomem()
functions.)
It also doesn't mention when to use which variant. (I'm guessing newer code should use the enomem variant.)
Separately, Documentation/Patterns.md has a section on "Fallible Constructors" which does mention adopt_nonnull_own_or_enomem
but not the more convenient try_make<>()
wrapper around it. (It also doesn't mention refptrs.)
Suggestions:
(I'm not sure those are the right suggestions, though.)
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too