/in/correct/dlist.c:14:38: error: implicit conversion from enumeration type 'dlistValueType' (aka 'enum dlistValueType_t') to different enumeration type 'dlistSortMethod' (aka 'enum dlistSortMethod_t') [-Werror,-Wenum-conversion]
if (fn(i->value,j->value,TYPE)==1)
~~ ^~~~
/in/correct/dlist.c:50:1: error: control may reach end of non-void function [-Werror,-Wreturn-type]
}
^
/in/correct/dlist.c:87:2: error: extra ';' outside of a function [-Werror,-Wextra-semi]
};
^
/in/correct/dlist.c:90:11: error: initializing 'list *' (aka 'struct linklist *') with an expression of type 'dlist_const' (aka 'const void *') discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
list* temp=this;
^ ~~~~
/in/correct/dlist.c:97:2: error: extra ';' outside of a function [-Werror,-Wextra-semi]
};
^
/in/correct/dlist.c:103:12: error: assigning to 'char *' from 'const char *' discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
nd->var=key;
^~~~
/in/correct/dlist.c:106:2: error: extra ';' outside of a function [-Werror,-Wextra-semi]
};
^
/in/correct/dlist.c:111:26: error: incompatible pointer types passing 'int (void *, void *, dlistValueType)' (aka 'int (void *, void *, enum dlistValueType_t)') to parameter of type 'int (*)(void *, void *, dlistSortMethod)' (aka 'int (*)(void *, void *, enum dlistSortMethod_t)') [-Werror,-Wincompatible-pointer-types]
sortNode(listDst,inc,LF->first->value,LF->TYPE);
^~~
/in/correct/dlist.c:8:30: note: passing argument to parameter 'fn' here
void sortNode(list* LF, int(*fn)(void*, void*, dlistSortMethod), void* temp, dlistValueType TYPE)
^
/in/correct/dlist.c:113:26: error: incompatible pointer types passing 'int (void *, void *, dlistValueType)' (aka 'int (void *, void *, enum dlistValueType_t)') to parameter of type 'int (*)(void *, void *, dlistSortMethod)' (aka 'int (*)(void *, void *, enum dlistSortMethod_t)') [-Werror,-Wincompatible-pointer-types]
sortNode(listDst,dec,LF->first->value,LF->TYPE);
^~~
/in/correct/dlist.c:8:30: note: passing argument to parameter 'fn' here
void sortNode(list* LF, int(*fn)(void*, void*, dlistSortMethod), void* temp, dlistValueType TYPE)
^
/in/correct/dlist.c:115:2: error: extra ';' outside of a function [-Werror,-Wextra-semi]
};
^
/in/correct/dlist.c:119:11: error: initializing 'list *' (aka 'struct linklist *') with an expression of type 'dlist_const' (aka 'const void *') discards qualifiers [-Werror,-Wincompatible-pointer-types-discards-qualifiers]
list *LF = this;
^ ~~~~
/in/correct/dlist.c:122:21: error: variable 'fp' is uninitialized when used here [-Werror,-Wuninitialized]
fprintf(fp, "%s=%s\n", LF->first->var, LF->first->value->strValue);
^~
/in/correct/dlist.c:118:13: note: initialize the variable 'fp' to silence this warning
FILE *fp;
^
= NULL
/in/correct/dlist.c:136:2: error: extra ';' outside of a function [-Werror,-Wextra-semi]
};
^
/in/correct/dlist.c:147:2: error: extra ';' outside of a function [-Werror,-Wextra-semi]
};
^
14 errors generated.