The memory allocation of buffers as documented in
has the unfortunate property that it is indicated as "obsolete" when compiling.
The proposed API using the "Result" and unique pointer construction is not obvious to use.
Could the documentation be updated for the new API? Complete example would be appreciated especially considering that the use of unique pointer seems to contradict the use of shared pointer in other parts of the API.