<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: The Principle of Least Astonishment</title>
	<atom:link href="http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/feed/" rel="self" type="application/rss+xml" />
	<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/</link>
	<description>So many lines, so little time</description>
	<lastBuildDate>Thu, 17 Dec 2009 05:41:54 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
	<item>
		<title>By: Robert</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-269</link>
		<dc:creator>Robert</dc:creator>
		<pubDate>Wed, 27 May 2009 18:52:03 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-269</guid>
		<description>Wow I was so lucky, I was having this issue with the Except method and I thought I had everything correct.  But I stumbled across this in my first hour of digging.  Thanks so much for such a complete explanation of what was happening.</description>
		<content:encoded><![CDATA[<p>Wow I was so lucky, I was having this issue with the Except method and I thought I had everything correct.  But I stumbled across this in my first hour of digging.  Thanks so much for such a complete explanation of what was happening.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Praveen</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-225</link>
		<dc:creator>Praveen</dc:creator>
		<pubDate>Wed, 21 Jan 2009 03:49:25 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-225</guid>
		<description>Pretty much landed into the same issue while trying to make the HashSet set operations to work. Realized that I needed to implement a custom comparer while comparing objects contained in the set, but stumbled at 2 places. Initially while implementing the IEqualityComparer, the GetHashCode() had to be overriden, which I was puzzled at &amp; secondly while debugging, the code walked-through the GetHashCode() even before the Equals() was invoked. Originally like yourself, I returned the obj.GetHashCode(), but the final output was not as expected. I tried reading MSDN to crack this nut, but of no use. I then landed into your blog after googling and realized I was not alone to land in this maze. Took your advise and boom, my resultset was as expected. Tx a ton, appreciate your hardwork.</description>
		<content:encoded><![CDATA[<p>Pretty much landed into the same issue while trying to make the HashSet set operations to work. Realized that I needed to implement a custom comparer while comparing objects contained in the set, but stumbled at 2 places. Initially while implementing the IEqualityComparer, the GetHashCode() had to be overriden, which I was puzzled at &amp; secondly while debugging, the code walked-through the GetHashCode() even before the Equals() was invoked. Originally like yourself, I returned the obj.GetHashCode(), but the final output was not as expected. I tried reading MSDN to crack this nut, but of no use. I then landed into your blog after googling and realized I was not alone to land in this maze. Took your advise and boom, my resultset was as expected. Tx a ton, appreciate your hardwork.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Eric</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-224</link>
		<dc:creator>Eric</dc:creator>
		<pubDate>Fri, 09 Jan 2009 13:51:22 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-224</guid>
		<description>Thanks for reading the full documentation for me.  Saved me from myself, and many more hours of frustration.  I read, but didn&#039;t READ, the documentation.  I know Object.GetHashCode should be overridden in classes that will be used as Hashtable keys, but what&#039;s that got to do with Intersect.  Well, apparently it stores the objects in some hash structure to make all those Equals perform better.  An implementation detail that should be irrelevant.  My take away is anywhere IEqualityComparer is used expect a Hash structure is going to be used some how.</description>
		<content:encoded><![CDATA[<p>Thanks for reading the full documentation for me.  Saved me from myself, and many more hours of frustration.  I read, but didn&#8217;t READ, the documentation.  I know Object.GetHashCode should be overridden in classes that will be used as Hashtable keys, but what&#8217;s that got to do with Intersect.  Well, apparently it stores the objects in some hash structure to make all those Equals perform better.  An implementation detail that should be irrelevant.  My take away is anywhere IEqualityComparer is used expect a Hash structure is going to be used some how.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: cranley</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-205</link>
		<dc:creator>cranley</dc:creator>
		<pubDate>Wed, 29 Oct 2008 13:32:39 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-205</guid>
		<description>@Tony - I thought about that as well, but the GetHashCode, if I recall correctly (and I very well may not be at this point) always gets called after Equals... maybe it&#039;s an application-lifetime caching thing?  I can&#039;t remember what was going on during my tests... either way, it is lame.  There&#039;s a few things that MS continues to do which, for me, don&#039;t make a whole lot of sense.  Their whole &quot;yield&quot; thing in linq expressions just doesn&#039;t make a whole lot of sense to me... but i digress.</description>
		<content:encoded><![CDATA[<p>@Tony &#8211; I thought about that as well, but the GetHashCode, if I recall correctly (and I very well may not be at this point) always gets called after Equals&#8230; maybe it&#8217;s an application-lifetime caching thing?  I can&#8217;t remember what was going on during my tests&#8230; either way, it is lame.  There&#8217;s a few things that MS continues to do which, for me, don&#8217;t make a whole lot of sense.  Their whole &#8220;yield&#8221; thing in linq expressions just doesn&#8217;t make a whole lot of sense to me&#8230; but i digress.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tony</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-204</link>
		<dc:creator>Tony</dc:creator>
		<pubDate>Wed, 29 Oct 2008 07:26:22 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-204</guid>
		<description>Me three (four?)!

Maybe there is the expectation that getting and comparing hashcode would potentially be a faster execution (in general), where as an Equals is going to do a deeper comparison?

Nevertheless, I was also surprised. ;-)</description>
		<content:encoded><![CDATA[<p>Me three (four?)!</p>
<p>Maybe there is the expectation that getting and comparing hashcode would potentially be a faster execution (in general), where as an Equals is going to do a deeper comparison?</p>
<p>Nevertheless, I was also surprised. <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-143</link>
		<dc:creator>Andy</dc:creator>
		<pubDate>Sun, 05 Oct 2008 01:39:01 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-143</guid>
		<description>Thanks - Saved me from the same fate.</description>
		<content:encoded><![CDATA[<p>Thanks &#8211; Saved me from the same fate.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Raghu</title>
		<link>http://lostinloc.com/2008/02/06/the-principle-of-least-astonishment/#comment-42</link>
		<dc:creator>Raghu</dc:creator>
		<pubDate>Sun, 22 Jun 2008 19:52:34 +0000</pubDate>
		<guid isPermaLink="false">http://lostinloc.wordpress.com/?p=3#comment-42</guid>
		<description>This bit me just now. Thanks for explaining as I did not have much time to read the documentation. I am surprised at the result too!</description>
		<content:encoded><![CDATA[<p>This bit me just now. Thanks for explaining as I did not have much time to read the documentation. I am surprised at the result too!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
