Super method name – surely they didn’t really mean that did they?

Whilst editing a WPF view, the XAML designer claimed it couldn’t display a child user control due to a null reference exception. Looking at the stack trace, I noticed a wonderfully named method…

Why would anyone want to create in instance slowly? Wouldn’t it have been better to have written a CreateInstanceReallyFast() method?

Mind you, it explains a few things about the XAML designer in Visual Studio!

Hmm, all sorts of strange thoughts fill my head. I wonder what the XAML designer code really looks like…

public XamlDesigner() {
  if (!UserIsFedUpWaiting) {
    while (UserIsNotDrummingFingersOnTheDesk) {
      Thread.Sleep(5000);
      if (AlreadyDelayedMoreThanThirtySeconds()) {
        VisualStudioIsNotResponding = true;
      }
    }
  }
  DisplayRandomExceptionInDesignerWindow();
  if (xamlDesigner.Exception.UserHasExpanded) {
    CrashVisualStudio();
  }
}

Ooh, aren’t I a cynic?

Be First to Comment

Please note that all comments are manually approved before being displayed, so don't bother posting spam, I'll just delete it

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.