Age | Commit message (Collapse) | Author |
|
After enabling the warning flags, the compiler was firing the following
warnings:
warning: implicit declaration of function ‘strdup’; did you mean ‘strcmp’? [-Wimplicit-function-declaration]
token->value = strdup("(");
^~~~~~
strcmp
warning: assignment to ‘char *’ from ‘int’ makes pointer from integer without a cast [-Wint-conversion]
token->value = strdup("(");
^
In order to fix these warnings above, I have decided to replace *strdup*
and *strndup* by *strcpy* and *strncpy* functions.
Signed-off-by: Johnny Richard <johnny@johnnyrichard.com>
|
|
Signed-off-by: Johnny Richard <johnny@johnnyrichard.com>
|
|
Signed-off-by: Johnny Richard <johnny@johnnyrichard.com>
|
|
We want to have different folders for src and objs files.
Signed-off-by: Johnny Richard <johnny@johnnyrichard.com>
|
|
This logic was inside the main function
Signed-off-by: Carlos Maniero <carlosmaniero@gmail.com>
|
|
Signed-off-by: Carlos Maniero <carlosmaniero@gmail.com>
|
|
warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has
type ‘size_t’ {aka ‘long unsigned int’} [-Wformat=]
Signed-off-by: Carlos Maniero <carlosmaniero@gmail.com>
|
|
Signed-off-by: Johnny Richard <johnny@johnnyrichard.com>
|