/////Declarations/////
typedef struct event_t {
char event[100];
int year;
} Event;
struct CalendarNode {
Event e;
struct CalendarNode *next;
};
/////////////////////////////
I'm getting an error from this line of code:
node->e.event = findEvent(temp);
where node points to the calendar node list [struct CalendarNode *list], e is the event of node, and event is in the form "EVENT:CSC209 Lecture" string in struct e, findEvent is a function that takes char *string as param and returns a pointer to char.
The error I'm getting is:
error: incompatible types in assignment
What am I doing wrong?
typedef struct event_t {
char event[100];
int year;
} Event;
struct CalendarNode {
Event e;
struct CalendarNode *next;
};
/////////////////////////////
I'm getting an error from this line of code:
node->e.event = findEvent(temp);
where node points to the calendar node list [struct CalendarNode *list], e is the event of node, and event is in the form "EVENT:CSC209 Lecture" string in struct e, findEvent is a function that takes char *string as param and returns a pointer to char.
The error I'm getting is:
error: incompatible types in assignment
What am I doing wrong?