title: What is special about HashSet<T> in .NET 3.5?
body: <p>Here's an interesting puzzle.</p>
  
  <p>I downloaded Snippet Compiler to try some stuff out, and wanted to write the following code:</p>
  
  <pre><code>using System;
  using System.Collections.Generic;
  
  public class MyClass
  {
      public static void RunSnippet()
      {
          HashSet&lt;int&gt; h = new HashSet&lt;int&gt;();
      }
  }
  </code></pre>
  
  <p>But the above code doesn't compile. I get:</p>
  
  <blockquote>
    <p>"The type or namespace name 'HashSet'
    could not be found (are you missing a
    using directive or an assembly
    reference?)"</p>
  </blockquote>
  
  <p>Clearly I'm not. It seems it can't find HashSet, yet it finds other types in the Systems.Collections.Generic namespace (e.g. List, SortedDictionary).</p>
  
  <p>What's the explanation for this? Presumeably Snippet Compiler is just using the standard Framework compiler under the covers...</p>
  
  <p>I would be interested to know why this doesn't work.</p>