title: Why are people using magic values instead of null in their code?
body: <p>I have seen this in legacy code and in some .NET open source projects. 
  I can't imagine a reason to do this. Just using "null" seems so much easier to me.</p>
  
  <p>Example:</p>
  
  <pre><code>public class Category
  {
     int parentID;
  
     bool HasParent
     {
        get
        {
            return parentID != -1;
        }
     }
  }
  </code></pre>
  
  <p>versus</p>
  
  <pre><code>public class Category
  {
     int parentID;
  
     bool HasParent
     {
        get
        {
            return parentID != null;
        }
     }
  }
  </code></pre>