What does #include actually do?

后端 未结 6 1497
广开言路
广开言路 2020-12-15 04:25

In C (or a language based on C), one can happily use this statement:

#include \"hello.h\";

And voila, every function and variable in

6条回答
  •  自闭症患者
    2020-12-15 04:42

    It's part of the preprocessor. Have a look at http://en.wikipedia.org/wiki/C_preprocessor#Including_files. And yes, it's just copy and paste.

提交回复
热议问题