开发者

Light-weight Stand-Alone C# Debugger

开发者 https://www.devze.com 2023-04-01 13:54 出处:网络
I\'ve been searching around the internet - and StackOverflow - for some recommendations on some lightweight .NET debuggers, but so far I haven\'t had a lot of luck. Some articles/posts are either pret

I've been searching around the internet - and StackOverflow - for some recommendations on some lightweight .NET debuggers, but so far I haven't had a lot of luck. Some articles/posts are either pretty dated, or otherwise don't exactly suit me needs.

What I'm s开发者_开发问答pecifically looking for is a very light-weight .NET debugger that I can wrap into my application, where I can create a "Debug mode" for administrators/developers. Because this application is very specific to the data, and environment it runs in, and features some scripting as well, it would be really useful to allow users the ability to debug their scripts, and in some cases the underlying engine.

In short, the requirements are:

  1. Lightweight,
  2. Allows users to set up custom breakpoints,
  3. And finally, allows users to step-through code

I could use the standard Visual Studio debugger, and use Debugger.Break(), but ultimately, this fails requirement number 1 of it being lightweight - I need something I can wrap into my application.


The CLR Managed Debugger (mdbg) Sample should get you started.


What about using the CSharpCodeProvider class? This will at least provide compiling, and I believe will provide debugging info. Although I'm not sure of the detail. Maybe between the CLR mdbg as @Eric recommends and the CodeProvider, you will get what you want.

You should be able to compile stand-alone scripts and debug. Although, it would be impossible to debug the application itself, while it is running - a point I certainly missed while @Hans is sharp enough to point out in his comment.


.NET Framework 2.0 Software Development Kit contains what you want

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号