i was following a tutorial on how to make a simple sqlite clone in c and the tutorial mentioned building a struct called Row and it's defined below:
typedef struct
{
int id;
char name[COLUMN_USERNAME_SIZE];
char email[COLUMN_EMAIL_SIZE];
}Row;
and it was defined a preprocessor macro to get the size of a member of that struct but i can't understand its definition. it's defined below:
#define size_of_attribute(Struct, Attribute) sizeof(((Struct*)0)->Attribute)
so, what does the tutorial mean here by using a name of a struct not an object of it and why use the * operator and most importantly, what does 0 mean here?