The Consequences of Performance Optimizations

I wanted to write a post today about a very interesting bug we just came across related to Refactoring.  As i just blogged about verification, i thought that this would be a good followup.  First, a bit of background.  Referencing the previous post, we can see the following Q/A about refactoring: Why is it important?…

28

The more things change

A while back we got an MSDN feedback report about a crash a customer was experiencing.  The customer had the following code: class A : B {}class B : A {}class C : B { override //Type space here} At this point the IDE would just up and vanish.  What happened?  Well, (as you can…

15

The future of the C# language

PDC is coming up soon, and the session list has been posted. One thing i wanted to point out was the abstract for a session that the C# team will be giving on version 3.0 of the language: C#: Future Directions in Language Innovation from Anders Hejlsberg Join Anders Hejlsberg, Distinguished Engineer and chief architect…

45

Pop Quiz!

Alright class.  Pop quiz time.  Say you have the following code: namespace What { class The { public static void Heck(uint[] array) { if (typeof(uint) != array.GetValue(0).GetType()) { throw new PleaseExplainThisToMeException(); } } }} Under what circumstances could you expect the “PleaseExplainThisToMeException” thrown? Note: You should be able to make the exception get thrown by…

15

Refactoring Verification

I posted a blog post from JavaOne where i stated:  “I did try out several of [Netbean’s] refactorings, and was pleased with them for the most part.  However, i tried a rename refactoring that changed the meaning of my code, and they did no verification of the rename to detect and warn me about this. …

6