title: What's the strangest corner case you've seen in C# or .NET?
body: <p>I collect a few corner cases and <a href="http://www.yoda.arachsys.com/csharp/teasers.html" rel="nofollow noreferrer">brain teasers</a> and would always like to hear more. The page only really covers C# language bits and bobs, but I also find core .NET things interesting too. For example, here's one which isn't on the page, but which I find incredible:</p>
  
  <pre><code>string x = new string(new char[0]);
  string y = new string(new char[0]);
  Console.WriteLine(object.ReferenceEquals(x, y));
  </code></pre>
  
  <p>I'd expect that to print False - after all, "new" (with a reference type) <em>always</em> creates a new object, doesn't it? The specs for both C# and the CLI indicate that it should.  Well, not in this particular case. It prints True, and has done on every version of the framework I've tested it with. (I haven't tried it on Mono, admittedly...)</p>
  
  <p>Just to be clear, this is only an example of the kind of thing I'm looking for - I wasn't particularly looking for discussion/explanation of this oddity. (It's not the same as normal string interning; in particular, string interning doesn't normally happen when a constructor is called.) I was really asking for similar odd behaviour.</p>
  
  <p>Any other gems lurking out there?</p>