“表达式评估器中的内部错误" [英] "Internal error in the expression evaluator"

查看:19
本文介绍了“表达式评估器中的内部错误"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Visual Studio 2015 的表达式计算器中遇到一个问题,显示表达式计算器中的内部错误",经过一些调查我发现这是由使用反射加载的程序集引起的.这个程序集不会抛出任何异常,但在那之后,vs exp 评估器将失败.这不是我加载的唯一程序集,还有一些不会影响评估者的良好工作程序集.

I've encountered a problem in expression evaluator of visual studio 2015 that says "Internal error in the expression evaluator", after some investigations I found that this is caused by an assembly that is loaded using reflection. This assembly wouldn't throw any exceptions but after that, vs exp evaluator will fail. This is not the only assembly that I load, there are some good working ones that don't influent the evaluator.

为了解决这个问题,我必须检查菜单 > 选项 > 调试 > 使用托管兼容模式",但这会禁用编辑 &继续"功能,我该怎么办?

To overcome this issue I had to check 'Menu > options > debugging > Use Managed Compatibility Mode' but this disables the 'Edit & Continue' feature, what can I do?

原因程序集的属性:

  • 其名称与主程序集相同(我改了名字但什么也没发生)
  • 我所有的项目都使用 dotNet 4.5
  • 所有根命名空间都相同(所有的程序集都是如此)

谢谢!

推荐答案

这听起来像是表达式计算器中的一个错误.要获得更好的解决方法,请不要选中使用托管兼容模式",而是选中使用旧版 C# 和 VB 表达式计算器".这将使您能够继续使用编辑并继续"以及最近几个版本中添加的其他功能.

That sounds like a bug in the expression evaluator. For a better workaround, instead of checking "Use Managed Compatibility Mode", check "Use the legacy C# and VB expression evaluators". This should enable you to continue using Edit and Continue as well as other features added within the last few releases.

关于表达式评估器的内部错误",您能否通过转到帮助-> 发送反馈-> 报告问题来打开问题?这将有助于我们在未来的版本中解决问题.

In terms of the "Internal error in expression evaluator", can you please open an issue by going to Help -> Send Feedback -> Report a problem? That will help us fix the problem in future releases.

这篇关于“表达式评估器中的内部错误"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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