我在理解 N1570 中的 §5.1.1.2/2 时遇到一些困难
I'm having some difficulties understanding §5.1.1.2/2 in N1570
N1570 中的§5.1.1.2/2:
Each instance of a backslash character (\
) immediately followed by a
new-line character is deleted, splicing physical source lines to form
logical source lines. Only the last backslash on any physical source
line shall be eligible for being part of such a splice. A source file
that is not empty shall end in a new-line character, which shall not
be immediately preceded by a backslash character before any such
splicing takes place.
阅读这一段我的理解是 只有 后退字符 (\
) 被删除,当它紧跟一个换行符时。但是在阅读了 SO 中关于这一段的其他帖子之后,我的印象是反冲字符和下一个换行符都从构成文件的源字符集中消除了。哪一个是正确的?
第一个短语的英文含糊不清,但第二个短语的意图很明确:删除反斜杠和换行
反斜杠和换行符都被删除。
a \
b
读作a b
。
N1570 中的§5.1.1.2/2:
Each instance of a backslash character (
\
) immediately followed by a new-line character is deleted, splicing physical source lines to form logical source lines. Only the last backslash on any physical source line shall be eligible for being part of such a splice. A source file that is not empty shall end in a new-line character, which shall not be immediately preceded by a backslash character before any such splicing takes place.
阅读这一段我的理解是 只有 后退字符 (\
) 被删除,当它紧跟一个换行符时。但是在阅读了 SO 中关于这一段的其他帖子之后,我的印象是反冲字符和下一个换行符都从构成文件的源字符集中消除了。哪一个是正确的?
第一个短语的英文含糊不清,但第二个短语的意图很明确:删除反斜杠和换行
反斜杠和换行符都被删除。
a \
b
读作a b
。