This has nothing to do with C as such. If you look in the include less.h file, you will see that the author has defined a number of preprocessor instructions. Some of them, as "public", are most likely readable. For instance:
#if HAVE_VOID #define VOID_POINTER void * #else #define VOID_POINTER char * #define void int #endif #if HAVE_CONST #define constant const #else #define constant #endif #define public
See how publication is defined. This has not changed anything and, as you have already disassembled it on a global scale. However, it is more readable and more suspicious that it is on a global scale. In addition, it can be argued that if the source is written sequentially like this, and a new version of C appears that has a public keyword, it is a matter of overriding the header file and recompiling for its actual use.
Pre-processed tricks like this can even be used in clever ways so that the same source compiles in different languages ββ(e.g. C ++ and Java). This is not what you should do, but it is possible.
Parameters such as HAVE_VOID, which you see in the example with less.h above, are usually specified as compiler (actually preprocessor) parameters at compile time. Therefore, if you have a compiler and a version of C that supports the void keyword, you must compile your source with:
g ++ -g -DHAVE_VOID -Wall myprog.C -o MyProg
Everywhere, when the author uses VOID_POINTER in the source, it will actually be considered by the compiler as:
void *
If you did not specify HAVE_VOID, the compiler will use instead
char *
which is a reasonable replacement.
TIP: Check the compiler options to see if you can just pre-process your sources. So you can look at the actual source that is sent to the compiler.