包含中的标准要求允许哪种令牌?例如,文件名中是否允许空格?
从cppreference上包含源文件
任何预处理标记(宏常量或表达式)都可以用作#include和__has_include(自C ++ 17起)的参数,只要它们扩展为由<>或“”包围的字符序列即可。
然后在解释
以实现定义的方式搜索文件。该语法的目的是搜索不受实现控制的文件。
此外,c ++ 20最终工作草案 5.8标头名称[lex.header]和
ISO / IEC 9899:1999 6.4.7标头名称(换行符>
和除外)"
。
header-name:
< h-char-sequence >
" q-char-sequence "
h-char-sequence :
h-char
h-char-sequence h-char
h-char:
any member of the source character set except new-line and >
q-char-sequence :
q-char
q-char-sequence q-char
q-char:
any member of the source character set except new-line and "
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句