Skip to content

Instantly share code, notes, and snippets.

@kateolenya kateolenya/main.c
Last active Mar 14, 2019

Embed
What would you like to do?
Private variables in struct in C
#include "private_var.h"
#include <stdio.h>
int main()
{
struct Contact * Tony;
Tony = create_contact();
// printf( "Mobile number: %d\n", Tony->mobile_number);
// will cause compile time error
delete_contact( Tony );
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.