Is it possible to exclude the entire standard header file due to one method?

I would like to call the function "C"

fabs(double); 

many times in my program, but I do not want to include the entire header file. Is it possible?

+4
source share
3 answers

No need to include the whole file.
Unused materials will not be compiled into your executable file.

+17
source

Yes, you can manually prototype it. Just add

 double fabs(double x); 

to the beginning of the source file.

+6
source

you can declare this function yourself, but why do you want to avoid including a header file?

+3
source

Source: https://habr.com/ru/post/1286790/


All Articles