0_0_22426799_4471.cpp: In function 'IntList* newList(int)':
0_0_22426799_4471.cpp:15:46: error: invalid conversion from 'void*' to 'listptr {aka IntList*}' [-fpermissive]
listptr p = malloc(sizeof(struct IntList));
^
0_0_22426799_4471.cpp:18:45: error: invalid conversion from 'void*' to 'int*' [-fpermissive]
p->array = malloc(capacity * sizeof(int));
^
0_0_22426799_4471.cpp: In function 'void addInt(int, listptr)':
0_0_22426799_4471.cpp:27:70: error: invalid conversion from 'void*' to 'int*' [-fpermissive]
int *newArray = realloc(p->array, (sizeof(int)) * p->capacity);
^
|