Implement conditional compilation
authorLukas Jiriste <ljiriste@student.42prague.com>
Thu, 28 Mar 2024 10:40:14 +0000 (11:40 +0100)
committerLukas Jiriste <ljiriste@student.42prague.com>
Thu, 28 Mar 2024 10:40:14 +0000 (11:40 +0100)
commitd9f489d226da5cf5a5985ef841fa6ef11a51c468
treed159e4e3d4b5c81ffde99480d77e96d2f7b08681
parent29613319e593e2349c7de434ab87f2865f2fcbc2
Implement conditional compilation

Before this commit, compilation would stop at file parsing.c
with error (warning + -Werror) caused by -Wtype-limits.
Conditional compilation is added so that the offending if statement
is not present, when not needed.

The #if directive could have only been set up around the problematic
if statement. The 42 Norm however forbids using macros anywhere but
the global scope.

This made me write the the affected functions twice, which then broke
the 5 function limit per .c file. Hence this commit is quite large
for such a small change.
philo/Makefile
philo/inner_pars_arg.c [new file with mode: 0644]
philo/pars_arg.c [new file with mode: 0644]
philo/parsing.c
philo/parsing.h [new file with mode: 0644]
philo/parsing_misc.c
philo/philo.h