title: Why cast null before checking if object is equal to null?
body: <p>I was looking through the "<a href="http://microsoftnlayerapp.codeplex.com/" rel="noreferrer">Domain Oriented N-Layered .NET 4.0 Sample App</a>" project and ran across some code that I do not understand.  In this project they often use syntax like the following to check arguments for null: </p>
  
  <pre><code>public GenericRepository(IQueryableContext context,ITraceManager traceManager)
  {
      if (context == (IQueryableContext)null)
              throw new ArgumentNullException("context", Resources.Messages.exception_ContainerCannotBeNull);
  </code></pre>
  
  <p>Why would you cast null to the type of the object you are checking for null? </p>