gpt4 book ai didi

c++ - g++ -E 选项输出

转载 作者:塔克拉玛干 更新时间:2023-11-02 23:57:57 24 4
gpt4 key购买 nike

使用这个选项我在预处理后接收文件。有很多行,例如:

# 91 "/usr/include/stdint.h" 3 4

这些数字是什么意思?首先我认为 #91 是包含文件的行数,但事实并非如此。关于 3 4 我完全不知道。

最佳答案

根据 the official documentation ,该行的格式为:

# linenum filename flags

linenum 指定以下行源自 filename 的该行号。然后就是四个flag:

  • 1 - 新文件的开始
  • 2 - 返回文件
  • 3 - 系统头文件
  • 4 - 视为包裹在 extern "C"

那么让我们来解释你的线标:

# 91 "/usr/include/stdint.h" 3 4

以下行源自 /usr/include/stdint.h 的第 91 行。它是一个系统头文件,应被视为包装在 extern "C" 中。

关于c++ - g++ -E 选项输出,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15679756/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com