我无法在VS2015~2017中使用特殊字符(日语)构建我的项目 [英] I cant build my project using special characters(Japanese) in VS2015~2017

查看:59
本文介绍了我无法在VS2015~2017中使用特殊字符(日语)构建我的项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

public enum Test
        {
            test・something = 7436,
        }


它在VS 2013中正常工作但是从VS2015,特殊字符"·"在日语中但VS认为这是"。"。所以它显示错误,我无法构建我的项目。

It work fine in VS 2013 but from VS2015, Special character "・" in Japanese but VS think this is ".". So It show error, and I cant build my project.


错误:

Error:

严重性    代码    说明   

错误     CS1056    意外字符'·'     

错误     CS0116    命名空间不能直接包含字段或方法等成员    



Severity    Code    Description   
Error    CS1056    Unexpected character '・'     
Error    CS0116    A namespace cannot directly contain members such as fields or methods    

我该如何解决这个问题?

How can I fix this problem?

推荐答案

你好Kirsi Yin,

Hi Kirsi Yin,

感谢您在这里发帖。

这是因为很多更多
IntelliSense代码是 由Microsoft在Visual Studio 2015中添加。您可以从$获取更多信息b $ b Q& A Visual Studio社区2013和2015预览版

This is because much more IntelliSense code areadded by Microsoft in Visual Studio 2015. You can get more info about it from the Q & A on Visual Studio Community 2013 and 2015 Preview.

可以切换的 Roslyn Analyzers 创建一些错误:右键单击项目的参考>分析程序,"打开活动规则集"

Some errors are created by Roslyn Analyzers that can be toggled: Right-click on project's References > Analyzers , "Open Active Rule Set"

然后切换有问题的错误:

Then toggle the error in question:

但错误CS1056&有问题的CS0116 不由Roslyn Analyzers处理。所以我们不能使用特殊字符"·"在Visual Studio 2015及更高版本中。您还可以向Microsoft报告此问题:

But the error CS1056 & CS0116 in question are not handled by Roslyn Analyzers. So we could not use the special character "・" in the Visual Studio 2015 and later. You can also report this issue to Microsoft:

https://connect.microsoft.com/VisualStudio/Feedback

https://connect.microsoft.com/VisualStudio/Feedback

< span style ="font-family:'Times New Roman',serif; font-size:10pt">

希望这可以帮到你。

Hope this can help you.


这篇关于我无法在VS2015~2017中使用特殊字符(日语)构建我的项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆