paleolimbot commented on issue #598: URL: https://github.com/apache/arrow-adbc/issues/598#issuecomment-1517770523
For nanoarrow the C++ helpers header has been absolutely essential...without it it's very easy to leak memory when mixed with other C++ idioms (mostly just this part https://github.com/apache/arrow-nanoarrow/blob/main/src/nanoarrow/nanoarrow.hpp#L107-L147 ). That implementation was basically trying to replicate the syntax + move-only semantics of `std::unique_ptr<T, Deleter>` while avoiding a heap allocation. I should almost certainly provide a return value helper, too, because the nanoarrow user code that I've read so far does a lot of ignoring of return values. `NANOARROW_RETURN_NOT_OK()` works pretty well but forces the use of pointer output arguments (e.g., https://github.com/apache/arrow-adbc/blob/main/c/driver/postgresql/postgres_type.h#L252-L254 ). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
