c# - vs code c# omnisharp,如何调试外部库

标签 c# debugging visual-studio-code omnisharp

我正在尝试在 visual studio 代码中单步执行我的 ASP 网络核心库代码,但不知道如何从根本上禁用“仅我的代码”并附加 pdb。

断点命中期间检查 omnisharp 行为的默认堆栈是:

MyNamespace.MyCLass.function()    
[External Code] (\Unknown Source:0)

如何调试外部库代码?

最佳答案

看来我需要根据以下内容编辑 vs code 的 launch.json 工作区文件:

https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md 该部分与 "justMyCode":false , "requireExactSource": false"symbolPath": [ "/Volumes/symbols"]

现在的问题是符号。无法找到公开发布的 asp net mvc 的 .net 核心符号。 我将不得不手动编译 https://github.com/aspnet/Mvc ,以及我感兴趣的所有其他中间件。

关于c# - vs code c# omnisharp,如何调试外部库,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43847641/

相关文章:

c# - 为什么我尝试在 C# 中实现基本自旋锁时会得到这个结果?

visual-studio-code - Visual Studio Code 水平和垂直拆分

visual-studio-code - 停止自动完成 VS Code 中的/* 注释

c# - 调整 Controller 操作中的参数名称以映射 HTTP 请求参数

c# - 在任务栏中显示隐藏窗口的图标

c++ - 调试 "one line"方法

.net - MyBase(基础)对象属性未在调试器中显示实际值

jquery - 如何查看使用模板生成的 jquerymobile 源代码?

visual-studio-code - 更改 Visual Studio Code 中的代码片段位置

c# - 指定的包含路径无效。 EntityType '*Propiedad' 未声明名称为 'Nombre' 的导航属性