<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Head.SmackOnTable(); &#187; Spleen Vent</title>
	<atom:link href="http://www.unauthorised-access.com/category/spleen-vent/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.unauthorised-access.com</link>
	<description>Contains Nuts.</description>
	<lastBuildDate>Fri, 02 Jul 2010 17:46:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>var – Considered harmful</title>
		<link>http://www.unauthorised-access.com/2009/05/var-considered-harmful/</link>
		<comments>http://www.unauthorised-access.com/2009/05/var-considered-harmful/#comments</comments>
		<pubDate>Thu, 07 May 2009 23:58:08 +0000</pubDate>
		<dc:creator>Monty</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Spleen Vent]]></category>

		<guid isPermaLink="false">http://www.unauthorised-access.com/2009/05/var-considered-harmful/</guid>
		<description><![CDATA[There seems to be a new phenomenon in the c#.net 3.5 world, where people are using the “var” keyword, because, well I&#8217;m guessing they are lazy. Take this example, what is MORE READABLE: var sourceRect = new ComparisonRectangleContainer(); OR ComparisonRectangleContainer sourceRect = new ComparisonRectangleContainer(); Now, I know that will be straight forward, you can see [...]]]></description>
			<content:encoded><![CDATA[<p>There seems to be a new phenomenon in the c#.net 3.5 world, where people are using the “var” keyword, because, well I&#8217;m guessing they are lazy. Take this example, what is MORE READABLE:</p>
<div style="font-size: 9pt; background: #242424; color: #e8f3f6; font-family: profontwindows">
<p style="margin: 0px"><span style="color: #8ac6f2">var</span> sourceRect = <span style="color: #8ac6f2">new</span> <span style="color: #cae682">ComparisonRectangleContainer</span>();</p>
</div>
<p>OR</p>
<div style="font-size: 9pt; background: #242424; color: #e8f3f6; font-family: profontwindows">
<p style="margin: 0px"><span style="color: #cae682">ComparisonRectangleContainer</span> sourceRect = <span style="color: #8ac6f2">new</span> <span style="color: #cae682">ComparisonRectangleContainer</span>();</p>
</div>
<p>Now, I know that will be straight forward, you can see what the new type is, it will be a ComparisonRectangleContainer, but what happens when you use var when getting a response from a method, like the following:</p>
<div style="font-size: 9pt; background: #242424; color: #e8f3f6; font-family: profontwindows">
<p style="margin: 0px"><span style="color: #8ac6f2">var</span> parallelCombiner = FirstPass();</p>
</div>
<p>Now, what does FirstPass return? Is it an IList&lt;String&gt;? No, I have to mouseover to find out:</p>
<p><a href="http://www.unauthorised-access.com/wp-content/uploads/2009/05/image7.png"><img style="border-right: 0px; border-top: 0px; display: inline; border-left: 0px; border-bottom: 0px" title="image" src="http://www.unauthorised-access.com/wp-content/uploads/2009/05/image-thumb7.png" border="0" alt="image" width="457" height="33" /></a></p>
<p>Ok, so it turns out it returns an ImageParallelCombiner, the first bit of code does not make it clear.</p>
<p><strong>You should always write code for HUMANS, not the compiler</strong></p>
<p>The following is PERFECTLY valid c#.net code, but is it good code?</p>
<div style="font-size: 9pt; background: #242424; color: #e8f3f6; font-family: profontwindows">
<p style="margin: 0px"><span style="color: #cae682">var </span>@this = <span style="color: #8ac6f2">new</span> @class();</p>
<p style="margin: 0px"><span style="color: #2b91af"> </span></p>
<p style="margin: 0px">@base.@stackalloc(<span style="color: #8ac6f2">delegate</span>(@if @event)</p>
<p style="margin: 0px">{</p>
<p style="margin: 0px"><span style="color: #2b91af"> </span><span style="color: #8ac6f2">if</span> (!@return.@bool(@event)) <span style="color: #8ac6f2">return</span>;</p>
<p style="margin: 0px"><span style="color: #2b91af"> </span>@is.@const(<span style="color: #6afd51">&#8220;S["</span> +@event + <span style="color: #6afd51">"] matched T["</span> + @return.@override(@event) + <span style="color: #6afd51">"]&#8220;</span> );</p>
<p style="margin: 0px"><span style="color: #2b91af"> </span>@this.@implicit(@event);</p>
<p style="margin: 0px">});</p>
</div>
<p>Note – you can prefix variable names with @ if you want to use a keyword – i.e. @class is a valid variable name, so is _ (underscore) – perfect if you want to make things as hard as possible for people to read it, like the “var” keyword.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.unauthorised-access.com/2009/05/var-considered-harmful/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>I am quite worried about the standard of coding these days</title>
		<link>http://www.unauthorised-access.com/2008/11/i-am-quite-worried-about-the-standard-of-coding-these-days/</link>
		<comments>http://www.unauthorised-access.com/2008/11/i-am-quite-worried-about-the-standard-of-coding-these-days/#comments</comments>
		<pubDate>Tue, 18 Nov 2008 12:51:05 +0000</pubDate>
		<dc:creator>Monty</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Spleen Vent]]></category>
		<category><![CDATA[framework design]]></category>
		<category><![CDATA[wishfull thinking]]></category>

		<guid isPermaLink="false">http://www.unauthorised-access.com/?p=54</guid>
		<description><![CDATA[Ok, this is going to make me sound like a really old fart, which im not! Honest! I was reading the blog of a Microsoft developer, someone whos team owns the Framework Design Guidelines, someone who worked on the VS Code Analysis team, and worked on FxCop. He then later states: Im sorry, but WHAT [...]]]></description>
			<content:encoded><![CDATA[<p>Ok, this is going to make me sound like a really old fart, which im not! Honest!</p>
<p>I was reading the blog of a Microsoft developer, someone whos team owns the Framework Design Guidelines, someone who worked on the VS Code Analysis team, and worked on FxCop.</p>
<p><a href="http://www.unauthorised-access.com/wp-content/uploads/2008/11/windowclipping-73.png"><img class="aligncenter size-full wp-image-55" title="Sample from davesbox.com" src="http://www.unauthorised-access.com/wp-content/uploads/2008/11/windowclipping-73.png" alt="Sample from davesbox.com" width="500" height="284" /></a></p>
<p>He then later states:</p>
<p><a href="http://www.unauthorised-access.com/wp-content/uploads/2008/11/windowclipping-74.png"><img class="aligncenter size-full wp-image-56" title="Comment from DavesBox.com" src="http://www.unauthorised-access.com/wp-content/uploads/2008/11/windowclipping-74.png" alt="Comment from DavesBox.com" width="500" height="65" /></a></p>
<p>Im sorry, but WHAT THE F**K? Your not a fan of defensive coding, but you want us to do it in framework classes? With your code sample above, if label is null, guess what happens to your code? You may not like defensive coding, so you are going to assume that all of your code samples will work?</p>
<pre class="brush: csharp;">
SetLabelTextIfNotEmpty(null);
SetLabelTextIfNotEmpty(Label1);  // No instance
</pre>
<p>Please tell me how your code will react to this? I guarentee that it will throw a null reference exception, because, well im passing in null to your method!</p>
<p><strong>ALWAYS CHECK FOR NULL!</strong></p>
<p>Im sure this is a minor lapse on your part, Dave, and im sure your code does not usually reflect this &#8211; if we had someone on my team, coding like this, I would either insist they change the way they code, or I would shift them off my team. Not checking for simple things, like null, is a major lapse in coding. You simply cannot guarentee that it will not be null, and wishfull thinking and happy thoughts arnt going to change it.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.unauthorised-access.com/2008/11/i-am-quite-worried-about-the-standard-of-coding-these-days/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The British govt is run by arseholes</title>
		<link>http://www.unauthorised-access.com/2008/04/the-british-govt-is-run-by-arseholes/</link>
		<comments>http://www.unauthorised-access.com/2008/04/the-british-govt-is-run-by-arseholes/#comments</comments>
		<pubDate>Tue, 29 Apr 2008 01:15:27 +0000</pubDate>
		<dc:creator>Monty</dc:creator>
				<category><![CDATA[Misc]]></category>
		<category><![CDATA[Spleen Vent]]></category>

		<guid isPermaLink="false">http://www.unauthorised-access.com/2008/04/the-british-govt-is-run-by-arseholes/</guid>
		<description><![CDATA[Nottinghamshire police have apologised to a family who had to wait three hours after dialling 999 when an armed gang forced their way into their home. Source &#8211; http://news.bbc.co.uk/1/hi/england/nottinghamshire/7372106.stm Nottinghamshire police HAVE ADMITTED THEY CANNOT PROTECT YOU. So why cant we have the right to defend ourselves? If you have a weapon and &#34;use it [...]]]></description>
			<content:encoded><![CDATA[<blockquote><p>Nottinghamshire police have apologised to a family who had to wait three hours after dialling 999 when an armed gang forced their way into their home.</p>
</blockquote>
<p>Source &#8211; <a title="http://news.bbc.co.uk/1/hi/england/nottinghamshire/7372106.stm" href="http://news.bbc.co.uk/1/hi/england/nottinghamshire/7372106.stm">http://news.bbc.co.uk/1/hi/england/nottinghamshire/7372106.stm</a></p>
<p>Nottinghamshire police HAVE ADMITTED THEY CANNOT PROTECT YOU. So why cant we have the right to defend ourselves? If you have a weapon and &quot;use it in a threatening manner&quot;, you face prison, but criminals can just run around robbing people blind because they know the police cannot do anything.</p>
<p><strong>We should have a right to be able to use firearms to defend ourselves.</strong></p>
<p>And there is a simple test you can do to prove this &#8211; Would the armed gang have forced their way into the couple&#8217;s home, if they knew they were armed to the teeth? No, of course not.</p>
<p>If I had a legal firearm, and people broke into my house, this would have went down in one of two ways &#8211; I would have challenged them, told them to put down their weapons. If they accepted that, fair enough, I would let the police know. If not, I would shoot every one of them, and make sure they were dead. Yes, that involves shooting them in the head and in the chest while they are down. This way I can guarantee that they will NEVER harm anyone ever again.</p>
<p>This country&#8217;s police force is incompetent, they are more focused with drivers doing 35mph in a 30mph road at 3am (Who knows! Maybe a kid would run out in the middle of the road!), and giving out fines to people who &quot;drop litter&quot; (a piece of a sausage, that was eaten by birds in a matter of seconds), than do something about crime. </p>
<p>The country&#8217;s Crap Prosecution Service, who are known as flat batteries &#8211; because they always say &quot;No Charge&quot;, and who charge and prosecute innocent people. How do I know this? Because I was one of them. I was cycling home one day, when a drunk fuckwit decided to try and kick me off the bike. I stopped nearby, called the police, while I was doing this, fuckwit and his boyfriend decided to chase me to give me a kicking &#8211; I cycled away at speed, and jumped a red light, that was caught on CCTV. I was arrested when I went to the station and was offered a formal caution &#8211; I told the police officer to shove his caution up his arse (my exact words) &#8211; and appeared infront of the magistrate the day after. The magistrate agreed with me, that jumping a red light on a bike, while being chased with 2 guys with knifes was acceptable.</p>
<blockquote><p>&quot;Community fixers&quot;, who deal out underworld justice on the behalf of clients, are being used instead of police, a senior policeman has said.</p>
</blockquote>
<p>Source &#8211; <a title="http://news.bbc.co.uk/1/hi/uk/7370244.stm" href="http://news.bbc.co.uk/1/hi/uk/7370244.stm">http://news.bbc.co.uk/1/hi/uk/7370244.stm</a>&#160;</p>
<p>If there was a &quot;Community Fixer&quot; in the area, id have his number on speed dial. Id have a deal with him, ill scratch his back, he&#8217;ll scratch mine.</p>
<p>Feral kids are running around this country, and no one can do anything about them. Police cant touch them &quot;I know my rights&quot; they scream, citizens cant touch them. </p>
<p> Sooner or later, there are going to be more &quot;Community Fixer&quot;&#8217;s than police. And that&#8217;s when the fun happens.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.unauthorised-access.com/2008/04/the-british-govt-is-run-by-arseholes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Stating the obvious</title>
		<link>http://www.unauthorised-access.com/2008/01/stating-the-obvious/</link>
		<comments>http://www.unauthorised-access.com/2008/01/stating-the-obvious/#comments</comments>
		<pubDate>Thu, 10 Jan 2008 17:08:18 +0000</pubDate>
		<dc:creator>Monty</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Spleen Vent]]></category>

		<guid isPermaLink="false">http://blog.muntedharalhakim.net/archive/2008/01/10/stating-the-obvious-again.aspx</guid>
		<description><![CDATA[Well here is a nice lovely error I get at work: So I try the nHibernate website, and I get the really useful following information: Oh how useful. VERY useful. YOU HAVE NOT GIVEN ANY ADDITIONAL INFORMATION, ONLY REORGANISED WHAT&#8217;S SAID IN THAT DIALOGUE BOX. Maybe a link to the documentation? Incompetent twats.]]></description>
			<content:encoded><![CDATA[<div class="Section1">
<p class="MsoNormal">Well here is a nice lovely error I get at work:</p>
<p class="MsoNormal"><img id="Picture_x0020_1" src="http://blog.muntedharalhakim.net/images/blog_muntedharalhakim_net/stating_the_obvious/image001.png" alt="" width="419" height="279" /></p>
<p class="MsoNormal">So I try the nHibernate website, and I get the really useful following information:</p>
<p class="MsoNormal"><img id="Picture_x0020_2" src="http://blog.muntedharalhakim.net/images/blog_muntedharalhakim_net/stating_the_obvious/image002.png" alt="WindowClipping (8).png" width="565" height="123" /></p>
<p class="MsoNormal">Oh how useful. VERY useful. <strong>YOU HAVE NOT GIVEN ANY ADDITIONAL INFORMATION, ONLY REORGANISED WHAT&#8217;S SAID IN THAT DIALOGUE BOX</strong>. Maybe a link to the documentation?</p>
<p class="MsoNormal">Incompetent twats.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.unauthorised-access.com/2008/01/stating-the-obvious/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting &#8220;In the Zone&#8221;</title>
		<link>http://www.unauthorised-access.com/2007/12/getting-quotin-the-zonequot/</link>
		<comments>http://www.unauthorised-access.com/2007/12/getting-quotin-the-zonequot/#comments</comments>
		<pubDate>Thu, 06 Dec 2007 10:18:55 +0000</pubDate>
		<dc:creator>Monty</dc:creator>
				<category><![CDATA[Spleen Vent]]></category>

		<guid isPermaLink="false">http://blog.muntedharalhakim.net/archive/2007/12/06/getting-quotin-the-zonequot.aspx</guid>
		<description><![CDATA[I dont know about anyone else, iv never really been anyone else before, but I find getting into the zone quite hard, but when I get there, I really try to not let myself get knocked out. When im in the zone, I code really good, accurate code, very fast. I dont realize how much [...]]]></description>
			<content:encoded><![CDATA[<p>I dont know about anyone else, iv never really been anyone else before, but I find getting into the zone quite hard, but when I get there, I really try to not let myself get knocked out. When im in the zone, I code really good, accurate code, very fast. I dont realize how much I spend on the machine, and I can usually code till 2 or 3am.</p>
<p>A big problem I have with working in the office is Coworkers. The biggest problem I have, is Coworkers. When I get in the zone, and they ask me an unrelated question, it knocks me out of the zone. I loose all those tiny variable names and interface names that were zipping around in my head. I loose the name of the page that I was working on, and I forget what I was doing.</p>
<p>Headphones only work to an extent. A coworker who wants to know why his hosts file entry isnt working will keep trying to get my attention, regardless of weather im wearing headphones or not.</p>
<p><strong>What can I do?</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.unauthorised-access.com/2007/12/getting-quotin-the-zonequot/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
