4 ms·
Maybe it is just me, but whenever I come across a type as ugly as * const * const c_char I would create a type alias. That way I can remember what it is a month
by megaman821 11y ago
Maybe it is just me, but whenever I come across a type as ugly as * const * const c_char I would create a type alias. That way I can remember what it is a month later. Would this work in Rust?
type c_str = *const c_char
type c_str_arr = *const c_str
pub extern fn get_stuff(array: c_str_arr, length: size_t) -> c_str {...}
- FreeFull 11y agoYes, that exact code would work, except with some extra semicolons.