如何寻址 C4428 Visual C++ 的此实例关于字符文字的警告?
目前 Visual C++ 出现 C4428 警告
源中遇到的通用字符名
在以下代码的
const wchar_t someMagicValue = L'\ufffd';
我想解决此警告,并且我想知道以下内容是否
const wchar_t someMagicValue = L'\xfffd';
是完全等效的代码。
后面的代码和前面的代码完全等价吗?什么是更好的选择?
Currently Visual C++ issues C4428 warning
universal-character-name encountered in source
on the following code
const wchar_t someMagicValue = L'\ufffd';
I'd like to address this warning and I wonder whether the following:
const wchar_t someMagicValue = L'\xfffd';
will be fully equivalent code.
Will the latter code be fully equivalent to the former? What could be a better option?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
正如此处评论的
编译器警告(级别 4)C4428 (VS2010)
这是最有可能/只是 MSVC 中的一个错误/
另请参阅 此线程进行更多讨论
As commented here
Compiler Warning (level 4) C4428 (VS2010)
this is most likely /just a bug/ in MSVC
See also this thread for a bit more discussion
你试过这个吗?
Have you tried this?