VS.NET 2005 C# : IDE hang with simply code...
Today I was doing some small research work with generics in VS.NET 2005 professional RTM and I was just typing normal code when the IDE suddenly locked up, a hardcore hang with 100% CPU usage. After a kill process, I restarted the IDE, loaded the same testproject, went to the same line of code and typed the same text... bam! hangs again!
Now I was a little worried. As this is a little testproject with bogus code, just to try out some generic constructs to see if it all compiles and works out, it's nothing special really so if anything, the IDE should stay up and responsive. Well, not with this killer code apparently.
So, I saved the single code file and re-created a new project (Console, C#) and replaced the generated class' code with the code of my testproject. Completely new project, same code text. Went to the line I wanted to add code, typed in the code, and... you got it, it hangs again.
So, to reproduce, follow the steps outlined in the bugreport, available here. Test code can be retrieved from this link: http://www.xs4all.nl/~perseus/HangUp.cs
Steps to follow:
- Create a new C# Console application
- Copy the code from the above URL, the HangUp.cs code
- Select all code in the generated Class1 class in the console project and paste the copied code into the code window
- Go to the line string Value // ... (almost at the bottom)
- Remove the comment, and type a {
- Wait a second and the IDE hangs
- I can reproduce this every time, in Beta2 this isn't happening (on a box with Beta2, it works fine)