我在.cpp文件中遇到了以下代码。我不明白涉及头文件的结构或语法。我确实认识到这些特定的头文件与Android NDK有关。但是,我认为这个问题是关于C语法的一般问题。
这些似乎以某种方式是预处理器命令,因为它们以“#”开头。但是,它们不是典型的#include,#pragma,#ifndef,#define等命令。源文件有更多的1000个这样的事件引用了数百个不同的.h,.c,.cpp文件。
typedef int __time_t;
typedef int __timer_t;
# 116 "/home/usr/download/android-ndk-r8b/platforms/android-3/arch-arm/usr/include/machine/_types.h"
# 41 "/home/usr/download/android-ndk-r8b/platforms/android-3/arch-arm/usr/include/sys/_types.h" 2
# 33 "/home/usr/download/android-ndk-r8b/platforms/android-3/arch-arm/usr/include/stdint.h" 2
# 48 "/home/usr/download/android-ndk-r8b/platforms/android-3/arch-arm/usr/include/stdint.h"
typedef __int8_t int8_t;
typedef __uint8_t uint8_t;
编译器(GCC)似乎并没有抛出与这些行有关的任何错误。但是,我想了解他们的目的和功能。有人可以解释一下吗