VC程序调试经验

作者在 2008-06-08 11:39:55 发布以下内容
今天调试程序的时候
发现有个警告warning C4129: 'S' : unrecognized character escape sequence
查了MSDN

'character' : unrecognized character escape sequence

The character following a backslash (\) in a character or string constant was not recognized as a valid escape sequence.

As a result, the backslash is ignored and not printed, and the character following the backslash is printed.

To print a single backslash, specify a double backslash (\\).

但是在VC的出错行却怎么也没有看到字符 'S',怎么回事呢?、难道是VC错了!不可能

经过好长时间最后才发现这个是由于提示输出的是一个长字符串的输出,VC错误指示指向的是资格字符串的最后一行,而不是刚好是字符串 'S'出现的那一行。因此这类警告指定的位置表示所在的字符串有问题,而不是特指字符串所在行的那一部分有问题



经验 | 阅读 9811 次
文章评论,共1条
vfdff(作者)
2008-09-12 09:42
1
C1010 在Vs2008 中解决方法:<br />
[1]In the Solution Explorer pane of the project, right-click the project name, and then click Properties.<br />
[2]In the left pane, click the C/C++ folder. <br />
[3]Click the Precompiled Headers node. <br />
[4]In the right pane, click Create/Use Precompiled Header, and then click Not Using Precompiled Headers.
游客请输入验证码
浏览1943070次