2

I am experiencing weird issues during Visual Studio 2015 Community debugging a 32-bit C# application (C# 6, .NET 4.5.2) on Windows 8.1 x64.

If I do a couple of Edit and Continue iterations (i.e. break execution, change something, continue), after a while I will get a weird NullReferenceException thrown for a field which cannot possibly be null. When I then hover over the this instance for the "offending" object, it turns out that there are multiple fields with the same name inside that object (and for each pair of fields, one of them with the expected value, the other one null). This happened a couple of times already, and wasn't fixed after installing VS2015 Update 1 either.

It seems like a Roslyn issue to me, like it has problems recompiling after Edit and Continue. Is this a known issue that has workarounds?

vgru
  • 49,838
  • 16
  • 120
  • 201
  • 1
    Does this seem similar to your issue? https://github.com/dotnet/roslyn/issues/4575 – Jeroen Vannevel Dec 07 '15 at 15:30
  • @JeroenVannevel: yes, this looks *exactly* like my issue, thanks a lot, but I have looked through the projects inside and don't think I have auto-generated (wildcard) version numbers anywhere (I wrote I *think* because it's a monogame project, so there are some content-pipeline projects which are not plain old C# projects and don't seem to have a simple version number anywhere). I will check some more to see if I can repro and pinpoint my exact issue. You can add this as an answer because it's certainly helpful. – vgru Dec 07 '15 at 17:48
  • Once you found some extra info that can help the Roslyn devs, feel free to add it as your own answer. I imagine you'll be more on top of this than I am so you can update the post when it gets fixed. Good luck! – Jeroen Vannevel Dec 07 '15 at 22:39
  • It's been 3 years, both VS2015 Update 3 and VS2017 v15.7.5 are still broken in this way. VS2013 does not have this problem, so to debug my C# code I have to go back to VS2013. Is there really no other solution? – sun2sirius Aug 25 '18 at 03:40

0 Answers0