Skip to content
This repository has been archived by the owner on Sep 21, 2024. It is now read-only.

Alias primitive return types in FFI to support more explicit documentation about those types #148

Open
cdata opened this issue Nov 14, 2022 · 0 comments
Labels
Documentation Improvements or additions to documentation

Comments

@cdata
Copy link
Collaborator

cdata commented Nov 14, 2022

    Consider: FFI aliases for `NsString => char*`, `NsString|NsStringArray => char**` `NsBytes => [uint8_t]`. This could indicate not necessarily ownership, but the originator of the data (Rust or embedder) and the corresponding release function (e.g. `NsString` must call `ns_string_free()` rather than `free()`). Mostly applicable for return types, less so for method arguments (where we would probably want to keep the C primitive types)

Originally posted by @jsantell in #141 (comment)

@cdata cdata added the Documentation Improvements or additions to documentation label Nov 14, 2022
@cdata cdata moved this to 🏔️ Icebox in Subconscious + Noosphere Nov 14, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Documentation Improvements or additions to documentation
Projects
Status: 🏔️ Icebox
Development

No branches or pull requests

1 participant