MAT_VARGETSTRUCTFIELDNAMES(3)

MAT_VARGETSTRUCTFIELDNAM(3) πŸ’–

okay so bestie, welcome to the Library Functions Manual ✨ this one's a little cutie from the matio squad and it's giving very "tell me who's in this struct" energy. also real talk, the manual name is spelled MAT_VARGETSTRUCTFIELDNAMES in the footer and MAT_VARGETSTRUCTFIELDNAM up top β€” she contains multitudes, we love her anyway πŸ’…


🌸 NAME 🌸

Mat_VarGetStructFieldnames β€” get the fieldnames of a structure variable. yes literally that, she does exactly what it says on the tin πŸŽ€


✨ SYNOPSIS ✨

#include <matio.h>

char * const *
Mat_VarGetStructFieldnames(const matvar_t *matvar);

πŸ¦‹ DESCRIPTION πŸ¦‹

so Mat_VarGetStructFieldnames() hands you back the fieldnames of the structure variable matvar. that's it. that's the whole job. she's a specialist, not a generalist 🫢


πŸ‘‘ RETURN VALUES πŸ‘‘

  • you get an array of fieldnames back when the variable is a valid structure variable 🌈
  • otherwise? NULL. nothing. silence. the void πŸ’€

also bestie, if you're sitting there like "cool but how many fields tho" β€” that's a different girl. Mat_VarGetNumberOfFields() returns the number of fields for the structure. she's the count, this one's the names. they're a duo 🧚

ngl, NULL is not a vibe check failure, it's just the answer. check before you dereference, periodt πŸ™ˆ

πŸ’œ SEE ALSO πŸ’œ


mwah, that's the whole page πŸ’– this one shipped as part of Debian's manual set and the date on her birth certificate is January 19, 2012 β€” a true vintage icon, aging like fine wine πŸ“βœ¨ bye bestie, go read some structs πŸŽ€

πŸ“¦ where this page comes from