main.c文件
#include <stdio.h>
#include "hello.h"
int main()
{
add();
printf("hello world\n");
}
hello.h头文件
#ifndef __HELLO_H__
#define __HELLO_H__
void add();
#endif
预处理后的hello.i文件(部分节选)
# 2 "main.c" 2
# 1 "hello/hello.h" 1
# 5 "hello/hello.h"
void add();
# 3 "main.c" 2
int main()
{
add();
printf("hello world\n");
}
预处理后,生成的.i文件存在多行形如# linenum filename flags的代码行,其中linenum,表示下面的内容来自文件filename 的第几行,而对于