<?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>The Dumping Ground &#187; .NET</title>
	<atom:link href="http://ardvaark.net/category/technology/dotnet/feed" rel="self" type="application/rss+xml" />
	<link>http://ardvaark.net</link>
	<description>And who cares?</description>
	<lastBuildDate>Fri, 30 Jul 2010 21:14:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Continuations Are Worth Being Hot</title>
		<link>http://ardvaark.net/continuations-are-worth-being-hot</link>
		<comments>http://ardvaark.net/continuations-are-worth-being-hot#comments</comments>
		<pubDate>Mon, 22 May 2006 14:00:06 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Steve has noticed, via Don Box, that continuations are getting popular. I can tell you from personal experience that there is a ton of value to continuations in multiple arenas, not the least of which is web serving. Apache Cocoon has supported continuation-driven application flow for its web applications for quite some time now, either [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://hyperthink.net" title="Brain.Save()">Steve</a> has noticed, via <a href="http://pluralsight.com/blogs/dbox/archive/2006/05/20/24599.aspx" title="Bracha and Bray on Continuations">Don Box</a>, that <a href="http://hyperthink.net/blog/PermaLink,guid,03a07b8f-086d-4154-ae50-d4cc98860c49.aspx" title="call/cc">continuations are getting popular</a>.  I can tell you from personal experience that there is a ton of value to continuations in multiple arenas, not the least of which is web serving.</p>
<p><a href="http://cocoon.apache.org" title="Apache Cocoon">Apache Cocoon</a> has supported continuation-driven application flow for its web applications for quite some time now, either using Flowscript (ECMAScript with continuations, done in <a href="http://www.mozilla.org/rhino/" title="Rhino: JavaScript for Java">Rhino</a>), or via JavaFlow (which is currently beyond my ken).  Flow makes it amazingly easy to model complex behavior using the standard programmer-friendly syntax of loops, conditionals, and function calls.  It&#8217;s brilliant!</p>
<p>And in some other work I&#8217;m doing right now, I desperately wish for continuations in C#.  I am attempting to asynchronously decode buffers into message structures, and the painful callback-based approach used by .NET&#8217;s Begin/End/IAsyncResult approach makes it extraordinarily difficult to code.  In order to avoid blocking a thread, I am forced to either stitch together a confusing chain of callbacks, or read data in a larger blocks.  The problems with the former are lack of understandability and difficult debugging, and the problem with the latter is that message parsing often requires small chunks to be read to determine how much more is to be read to complete the message.</p>
<p>I yearn to be able to write code like the following, despite my unwieldy made-up syntax and lack of error checking.</p>
<p><code lang="C#">Message Decode(Stream stream)<br />
{<br />
&nbsp;&nbsp;&nbsp;BinaryReader reader = new BinaryReader(stream);<br />
&nbsp;&nbsp;&nbsp;Message msg = new Message();</p>
<p>&nbsp;&nbsp;&nbsp;msg.Foo = Continuation.CallWithCurrent(reader.ReadInt32);<br />
&nbsp;&nbsp;&nbsp;msg.Bar = Continuation.CallWithCurrent(reader.ReadInt32);</p>
<p>&nbsp;&nbsp;&nbsp;return msg;<br />
}<br />
</code></p>
<p>Then, the <code>BinaryReader</code> would support something like this:</p>
<p><code lang="C#">void ReadInt32(Continuation continuation)<br />
{<br />
&nbsp;&nbsp;&nbsp;// Set in the constructor.<br />
&nbsp;&nbsp;&nbsp;this.stream.BeginRead(this.buffer, 0, 4, delegate(IAsyncResult result)<br />
&nbsp;&nbsp;&nbsp;{<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;this.stream.EndRead(result);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;int result = this.ConvertBufferToInt32();<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;continuation(result);<br />
&nbsp;&nbsp;&nbsp;});<br />
}<br />
</code></p>
<p>I could write my deserialization function as a nice procedural list of instructions, and not have to worry about blocking a thread while I wait.  You could, of course, push the continuation call farther down the stack into the stream or socket or from whatever is being read.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/continuations-are-worth-being-hot/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fun With C# 2.0 Iterators</title>
		<link>http://ardvaark.net/fun-with-c-sharp-2-0-iterators</link>
		<comments>http://ardvaark.net/fun-with-c-sharp-2-0-iterators#comments</comments>
		<pubDate>Wed, 01 Mar 2006 13:37:51 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Code]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[In the little free time that I have, I have been messing around with writing a .NET program to help me with the large amount of photo metadata editing I want to do on all the photos I&#8217;ve been uploading to my Flickr photostream. It&#8217;s been fun doing some .NET again. It&#8217;s easy to forget [...]]]></description>
			<content:encoded><![CDATA[<p>In the little free time that I have, I have been messing around with writing a .NET program to help me with the large amount of photo metadata editing I want to do on all the <a href="http://ardvaark.net/uploading_tons_of_photos.html">photos I&#8217;ve been uploading</a> to my <a href="http://www.flickr.com/photos/ardvaark/">Flickr photostream</a>.</p>
<p>It&#8217;s been fun doing some .NET again.  It&#8217;s easy to forget how nice of a language C# is especially with all of the fancy new features 2.0 brings.  Last night, I came up with a fun little method of using <a href="http://msdn.microsoft.com/msdnmag/issues/06/00/C20/default.aspx">iterators</a>.</p>
<p><img src="/assets/add_photo_dialog.png" alt="Simple &quot;Add Photo&quot; dialog box" class="alignleft" /> Here&#8217;s the scenario:  I need to collect photo IDs for editing.  As a simple solution, I have a very small dialog box that contains a text field, an &#8220;Add Another&#8221; button, a &#8220;Done&#8221; button, and a &#8220;Cancel&#8221; button.  When the user clicks &#8220;Add Another,&#8221; I want to save the entered photo ID and re-display the dialog.  If they click &#8220;Done,&#8221; the currently entered ID should be saved, and the dialog should vanish.  Finally, if they click cancel, the current ID does not get saved, and the dialog disappears.</p>
<p>I have set up the <tt>DialogResult</tt> of the &#8220;Done&#8221; buttton to return with <tt>DialogResult.OK</tt>, and &#8220;Add Another&#8221; to return with <tt>DialogResult.Yes</tt>.  Here&#8217;s the code in the UI controller responsible for coordinating this:<br />
<code><br />
public IEnumerable<string> GetPhotoIds()<br />
{<br />
   AddPhotoDialog dialog = new AddPhotoDialog();</p>
<p>   DialogResult result = dialog.ShowDialog(this.parentWindow);</p>
<p>   while (result == DialogResult.Yes || result == DialogResult.OK)<br />
   {<br />
       yield return dialog.PhotoId;</p>
<p>       if (result == DialogResult.OK)<br />
       {<br />
           yield break;<br />
       }</p>
<p>       result = dialog.ShowDialog(this.parentWindow);<br />
   }<br />
}<br />
</code></p>
<p>Then, in the top-level UI controller, I can simply do:<br />
<code><br />
AddPhotoUIController controller = new AddPhotoUIController(this.mainForm);</p>
<p>foreach (string photoId in controller.GetPhotoIds())<br />
{<br />
    PhotoInfo info = this.FlickrApi.PhotosGetInfo(photoId);<br />
    this.CurrentBatch.Containers.Add(new SinglePhoto(info));<br />
}<br />
</code></p>
<p>Pretty slick.  I wish they had made this feature more general, though, and implemented full-on continuations.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/fun-with-c-sharp-2-0-iterators/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WS-Goldylocks &amp; The Seven Layers</title>
		<link>http://ardvaark.net/wsgoldylocks-amp-the-seven-layers</link>
		<comments>http://ardvaark.net/wsgoldylocks-amp-the-seven-layers#comments</comments>
		<pubDate>Fri, 15 Oct 2004 16:46:00 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[I&#8217;d like to comment on Steve&#8216;s post on the WS-* standards process, specifically on how the standards have been produced. A &#8220;real&#8221; standards process may or may not add any significant value to any given standard. Quite frankly, it depends a lot more on the people involved than anything else. What a &#8220;real&#8221; process certainly [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;d like to comment on <a href="http://hyperthink.net">Steve</a>&#8216;s <a href="http://hyperthink.net/blog/PermaLink,guid,f65e60e6-8dff-45ed-91cd-39c50b78d080.aspx">post on the WS-* standards process</a>, specifically on how the standards have been produced.  A &#8220;real&#8221; standards process may or may not add any significant value to any given standard.  Quite frankly, it depends a lot more on the people involved than anything else.  What a &#8220;real&#8221; process certainly adds is a lot more time until the standard is released.  Almost by definition, standards are required to be the least common denominator of functionality, and deriving that LCD is hard work.  But the world of web services is amazingly fast-paced.  It seems like XML was just barely gaining its foothold in people&#8217;s brains and suddenly people were talking about SOAP and services.  After that, we jumped into warp speed with <a href="http://msdn.microsoft.com/webservices/">everybody</a> and <a href="http://java.sun.com/webservices/index.jsp">their</a> <a href="http://www-130.ibm.com/developerworks/webservices/">brother</a> suddenly working together on <a href="http://www-106.ibm.com/developerworks/webservices/library/ws-secure/">WS-Security</a>, <a href="http://msdn.microsoft.com/webservices/community/workshops/default.aspx?pull=/library/en-us/dnglobspec/html/ws-trust.asp">WS-Trust</a>, and all the others.  And as Steve points out, while the standards may not be &#8220;real,&#8221; they are real enough that different vendors bits can talk to one another.</p>
<p>All of this reminds me of my college networking class.  <a href="http://www.cs.rose-hulman.edu/faculty/faculty_pics/young.jpg" class="floatbox" rel="floatbox.168">Frank</a> taught us about the <a href="http://en.wikipedia.org/wiki/OSI_model">7-Layer OSI Model</a> for networks (what <a href="http://blog.christopherschultz.net">Chris</a> joking refers to as &#8220;The Burrito&#8221;).  The OSI Model was hashed through and arduously toiled over by the major industry players until it was agreed upon by all.  And afterwards, there was much rejoicing!!  Now everybody could understand how networks were to be constructed, and a new era of interoperability was born!</p>
<p>And then Frank told us to forget about the OSI Model.  Nobody used it.  The standard had been stillborn.  While the industry had been fighting, the <a href="http://en.wikipedia.org/wiki/ARPANET">ARPANET</a>, using a <a href="http://en.wikipedia.org/wiki/DoD_model">much simpler model</a>, had proven Good Enough.  It was so Good Enough, in fact, that it eventually became the <a href="http://en.wikipedia.org/wiki/Internet">Internet</a> that we all now know and love.  Nobody uses any other kind of network!</p>
<p>The moral of the story is that Good Enough running code will usually produce a de-facto standard that will trump everything else.  Why bother with a full standards process for the Web Service languages?  They are Good Enough as it is, despite the myriad of pitfalls we are sure to uncover in the future.  And I have full faith in the community of developers to continue to produce such de-facto standards <em>provided corporate politics and short-term profit are not allowed to trump the engineers&#8217; best judgements.</em></p>
<p>Read that again.</p>
<p><em>The community of developers will continue to produce such de-facto standards provided corporate politics and short-term profit are not allowed to trump the engineers&#8217; best judgements.</em></p>
<p>Be careful.  It&#8217;s already happening.  Some of the competing WS-* standards, such as <a href="http://www-106.ibm.com/developerworks/webservices/library/specification/ws-eventing/">WS-Eventing</a> and <a href="http://www-106.ibm.com/developerworks/library/specification/ws-notification/">WS-Notification</a>, seem to exist primarily because companies are competing for control of the specs.  Such fractures must be kept to a minimum if collaborative, <a href="http://en.wikipedia.org/wiki/Chaordic">chaordic</a> engineering is to ever produce de-facto standards as successful as TCP/IP.</p>
<p>It is a rare environment when Getting Things Done is universally accepted as more important than Protecting Your Turf.  We all need to keep the pressure up on the corporate powers-that-be to continue the cooperation that has so far proven very successful.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/wsgoldylocks-amp-the-seven-layers/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>New C# Operator</title>
		<link>http://ardvaark.net/new-c-operator</link>
		<comments>http://ardvaark.net/new-c-operator#comments</comments>
		<pubDate>Tue, 27 Jul 2004 22:26:00 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[How many times have you written a piece of code like this? public void Jump(string msg) { if (msg == null &#124;&#124; msg.Length == 0) { throw new ArgumentNullException("msg"); } // Jump! } I don&#8217;t know about you, but I write code like this all the time. It&#8217;s an important sanity check, and Microsoft recommends [...]]]></description>
			<content:encoded><![CDATA[<p>How many times have you written a piece of code like this?<br />
<code>
<pre>public void Jump(string msg)
{
   if (msg == null || msg.Length == 0)
   {
      throw new ArgumentNullException("msg");
   }

   // Jump!
}</pre>
<p></code></p>
<p>I don&#8217;t know about you, but I write code like this all the time.  It&#8217;s an important sanity check, and Microsoft recommends it.  But what happens if you change the name of the variable <code>msg</code>?  Suddenly, your code is wrong.  Sure, it&#8217;s syntactically correct and will compile just fine, but there is no longer a semantic link between the message returned by the <code>ArgumentNullException</code> and the code from which it was thrown.</p>
<p>I propose the addition to the C# language of the <code>nameof</code> operator.  Analagous to the existing <code>typeof</code> operator, the <code>nameof</code> operator will return the name of its operand as a string.  The example from above, then, would be rewritten as follows.<br />
<code>
<pre>public void Jump(string msg)
{
   if (msg == null || msg.Length == 0)
   {
      throw new ArgumentNullException(nameof(msg));
   }

   // Jump!
}</pre>
<p></code></p>
<p>It is important to note that the operand is still a full-fledged symbol.  Thus, in the example above, changing the name of the <code>msg</code> parameter will cause a compile-time error if the operand to the <code>nameof</code> operator is not also changed.<br />
The <code>nameof</code> operator will simply be syntactic sugar, and requires no changes to the CLR, and therefore also causes no change to the run-time performance of the code.</p>
<p>Why is this important?  After all, the above example is simplistic, even though it is a common case.  First of all, there are many more complicated cases that can occur.  As we all know, detailed error messages can go a long way towards helping troubleshoot and debug problems in our code.  My own personal guidelines for creating error messages are:</p>
<ol>
<li>Error messages must be unique to a given error condition.  You should <em>never</em> copy-and-paste error messages unless the root cause of the error really is identical; and in that case, you should think about refactoring your code because it sounds like you have some code duplication.  (The exception to this (pun intended) is the <code>catch</code> syntax, which requires multiple blocks to catch exceptions that do not have the same root.)</li>
<li>Error messages must have a detailed message explaining cause of the problem, including the names and values of any variables used to calculate the error condition.</li>
<li>Error messages should include a description for how to correct the problem.  This could be as simple as giving example known-good values, or it could be as complex as describing how to fix your Windows certificate store to have the right permissions.</li>
</ol>
<p>The <code>nameof</code> operator will go a long way towards ensuring consistency between error messages and code.</p>
<p>The other need for the <code>nameof</code> operator is the increasing intelligence of the development tools.  Refactoring tools have are quite in vouge, evidenced by the fact that Whidbey will be shipping with such tools bundled in.  As we continue to do less and less manual editing of our code, relying on a developer&#8217;s eye to find and fix such problems becomes more and more dangerous.</p>
<p>I came up with this idea when I was at <a href="http://avanade.com">Avanade</a> working with <a href="http://hyperthink.net/blog">Steve</a>, but I&#8217;ve never mentioned it publicly.  As I recall, at that time, Steve had the opportunity to have a quick chat with Anders Hejlsberg, the lead designer of C#, and he mentioned this.  I seem to recall he liked the idea, but it was one of those little things that would probably never happen.  Steve, am I making this up?</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/new-c-operator/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Re-De-Compiliation</title>
		<link>http://ardvaark.net/redecompiliation</link>
		<comments>http://ardvaark.net/redecompiliation#comments</comments>
		<pubDate>Sat, 03 Jul 2004 21:29:27 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[I was able to successfully de-compile and re-compile my MoleMan executable using FileDisassembler. It has a few problems generating incorrect code, although I assume that has more to do with Reflector&#8217;s de-compilation API than the plugin itself. Mostly, they centered around implicit operators, although it also forgot to add several necessary using statements. Overall, I&#8217;m [...]]]></description>
			<content:encoded><![CDATA[<p>I was able to successfully de-compile and re-compile my MoleMan executable using <a href="http://www.denisbauer.com/NETTools/FileDisassembler.aspx">FileDisassembler</a>.  It has a few problems generating incorrect code, although I assume that has more to do with Reflector&#8217;s de-compilation API than the plugin itself.  Mostly, they centered around implicit operators, although it also forgot to add several necessary <code>using</code> statements.</p>
<p>Overall, I&#8217;m very pleased.  Now I just have to go through and re-name variables and such to something less nonsensical.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/redecompiliation/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Need a Decompiler</title>
		<link>http://ardvaark.net/need-a-decompiler</link>
		<comments>http://ardvaark.net/need-a-decompiler#comments</comments>
		<pubDate>Fri, 02 Jul 2004 15:04:00 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[When I was still at Avanade, I wrote myself a little program called MoleMan to manage my SSH tunnels. It was really useful because I would often disconnect from the wired network and go wireless, and I wanted my tunnels to automatically re-connect. However, when I left the company, I accidentally left the source code [...]]]></description>
			<content:encoded><![CDATA[<p>When I was still at <a href="http://avanade.com">Avanade</a>, I wrote myself a little program called MoleMan to manage my SSH tunnels.  It was really useful because I would often disconnect from the wired network and go wireless, and I wanted my tunnels to automatically re-connect.  However, when I <a href="http://blog.ardvaark.net/article.php?story=20031014141049443">left the company</a>, I accidentally left the source code on my laptop, which got wiped.  All I had left was my binary install of the latest version that I had installed at home.</p>
<p>Fortunately, I had sent my friend Greg, of <a href="http://webneko.net">Neko</a> fame, a copy of my source code a few weeks earlier.  Well, there are a couple of bugs in MoleMan, and I want to fix them and release the program to others who might find it useful.  Unfortunately, I have discovered that I made some major changes to the program between the time I sent Greg the source and the final version I&#8217;m running.  So I need a decompiler.</p>
<p>I found a <a href="http://sharptoolbox.madgeek.com/Pages/Categoryefcdb6a1-ab30-4d40-ae58-fed5bbea5db9.aspx">good list</a>, but unfortunately none of the free tools will do an entire assembly in at once.  And everything else is not free.</p>
<p>Does anybody know of a good, free C# de-compiler that will do entire assemblies at once?  If so, please <a href="/profiles.php?uid=4">let me know</a>.</p>
<p><b>Update</b>: I have discovered the <a href="http://www.denisbauer.com/NETTools/FileDisassembler.aspx">FileDisassembler</a> plugin for <a href="http://www.aisto.com/roeder/dotnet">Reflector</a>.  Contrary to the name, it actually does de-compile, and it seems to generate pretty good code.  I&#8217;ll start from here and see how it works.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/need-a-decompiler/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Patching DotNetMock</title>
		<link>http://ardvaark.net/patching-dotnetmock</link>
		<comments>http://ardvaark.net/patching-dotnetmock#comments</comments>
		<pubDate>Wed, 19 May 2004 20:38:00 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[I have been working on a project at home for which I am using DotNetMock to create mock objects for my unit testing. Unfortunately, DotNetMock has a couple of problems with its dynamic generation features. The first is that it does not currently support methods on inherited interfaces, and the second is that it does [...]]]></description>
			<content:encoded><![CDATA[<p>I have been working on a project at home for which I am using <a href="http://sourceforge.net/projects/dotnetmock">DotNetMock</a> to create mock objects for my unit testing.  Unfortunately, DotNetMock has a couple of problems with its dynamic generation features.  The first is that it does not currently support methods on inherited interfaces, and the second is that it does not work correctly with non-primitive value types.</p>
<p>So I fixed those <a href="http://sourceforge.net/tracker/index.php?func=detail&amp;aid=944688&amp;group_id=54948&amp;atid=475411">two</a> <a href="http://sourceforge.net/tracker/index.php?func=detail&amp;aid=935311&amp;group_id=54948&amp;atid=475411">problems</a>.  Hopefully my <a href="http://sourceforge.net/tracker/index.php?func=detail&amp;aid=944925&amp;group_id=54948&amp;atid=475413">two</a> <a href="http://sourceforge.net/tracker/index.php?func=detail&amp;aid=956968&amp;group_id=54948&amp;atid=475413">patches</a> will get rolled in.</p>
<p>DotNetMock seems to be the extension of <a href="http://nmock.org">NMock</a>.  Many of the interfaces are the same, and NMock hasn&#8217;t been updated since last May.  However, there seems to be only one guy on the DotNetMock project, so I&#8217;m not sure how long-term the project is.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/patching-dotnetmock/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Nasty Error Upgrading to Mono 0.30.1</title>
		<link>http://ardvaark.net/nasty-error-upgrading-to-mono-0301</link>
		<comments>http://ardvaark.net/nasty-error-upgrading-to-mono-0301#comments</comments>
		<pubDate>Tue, 17 Feb 2004 01:48:00 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Blorg!! I&#8217;m trying to upgrade to Mono 0.30.1 (from 0.28) on samus, and it fails during the emerge with a nasty little error (found in the full text). It seems to stem from the fact that the build process is attempting to call the resource generator with the installed runtime, rather than the one it [...]]]></description>
			<content:encoded><![CDATA[<p>Blorg!!  I&#8217;m trying to upgrade to <a href="http://go-mono.com/archive/mono-0.30.1.html">Mono 0.30.1</a> (from 0.28) on samus, and it fails during the emerge with a nasty little error (found in the full text).  It seems to stem from the fact that the build process is attempting to call the resource generator with the installed runtime, rather than the one it just built.  I&#8217;ve unmerged the existing runtime and and attempting to emerge again in the hopes that it won&#8217;t get confused if there isn&#8217;t a runtime already installed.</p>
<p><b>Update:</b> So that fixed it.  Who knows if that was really the problem or not, but I was able to successfully emerge the package after I had unmerged it.  Now to get Dasblog running&#8230;</p>
</p>
<p><code>
<pre>
** (/usr/bin/monoresgen.exe:21345): WARNING **: cant resolve internal call to "System.Type::IsInstanceOfType(object)" (tested without signature also)

Your mono runtime and corlib are out of sync.
Corlib is: /var/tmp/portage/mono-0.30.1/work/mono-0.30.1/runtime/mscorlib.dll

When you update one from cvs you need to update, compile and install
the other too.
Do not report this as a bug unless you're sure you have updated correctly:
you probably have a broken mono install.
If you see other errors or faults after this message they are probably related
and you need to fix your mono install first.

Unhandled Exception: System.NullReferenceException: A null value was found where an object instance was required
in (unmanaged) System.Type:GetTypeFromHandle (System.RuntimeTypeHandle)
in  System.Threading.Thread:get_CurrentCulture ()
in  System.Globalization.CultureInfo:get_CurrentCulture ()
in  System.String:ToLower ()
in  .ResGen:GetReader (System.IO.Stream,string)
in  .ResGen:CompileResourceFile (string,string)
in  .ResGen:Main (string[])
</pre>
<p></code></p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/nasty-error-upgrading-to-mono-0301/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Decompiler Obfuscated</title>
		<link>http://ardvaark.net/decompiler-obfuscated</link>
		<comments>http://ardvaark.net/decompiler-obfuscated#comments</comments>
		<pubDate>Mon, 02 Feb 2004 13:30:58 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Oh the irony! I am definitely sad to see that Lutz Roeder has decided to obfuscate Reflector. Reflector is a great tool for exploring an assembly, discovering work-arounds for defects in APIs you can&#8217;t control, and poking at code for possible useful but undocumented types and methods.]]></description>
			<content:encoded><![CDATA[<p>Oh the irony!  I am definitely sad to see that <a href="http://www.aisto.com/Roeder/Frontier/">Lutz Roeder</a> has decided to <a href="http://www.aisto.com/Roeder/Frontier/Default.aspx?PermaLink=19">obfuscate Reflector</a>.  Reflector is a great tool for exploring an assembly, discovering work-arounds for defects in APIs you can&#8217;t control, and poking at code for possible useful but undocumented types and methods.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/decompiler-obfuscated/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>XSD As A Type System Redux</title>
		<link>http://ardvaark.net/xsd-as-a-type-system-redux</link>
		<comments>http://ardvaark.net/xsd-as-a-type-system-redux#comments</comments>
		<pubDate>Mon, 26 Jan 2004 20:02:00 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[.NET]]></category>

		<guid isPermaLink="false"></guid>
		<description><![CDATA[Steve has written a lot over the last few days on his belief the XSD is not a type system. This was one his favorite topics to toss around with me when we were both at Avanade. If you haven&#8217;t read his disserations, you should check out Part 1, Don Box&#8216;s reply, and Steve&#8217;s Part [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://hyperthink.net/blog">Steve</a> has written a lot over the last few days on his belief the XSD is not a type system.  This was one his favorite topics to toss around with me when we were both at <a href="http://avanade.com">Avanade</a>.  If you haven&#8217;t read his disserations, you should check out <a href="http://hyperthink.net/blog/PermaLink,guid,1c407222-5849-4fd0-a026-341633859105.aspx">Part 1</a>, <a href="http://www.gotdotnet.com/team/dbox">Don Box</a>&#8216;s <a href="http://www.gotdotnet.com/team/dbox/default.aspx?key=2004-01-24T09:20:54Z">reply</a>, and Steve&#8217;s <a href="http://hyperthink.net/blog/PermaLink,guid,dfaf9b81-fa67-4abb-a83a-4eb0f57118ac.aspx">Part 2</a>, in reply to Don.  It&#8217;s all great.</p>
<p>I find that I tend to side with Steve&#8217;s position that XSD is not a type system.  Although it can be used as a type system, it really is much more powerful at <b>not</b> being a type system.  If you are using it as such, you should really be using something simpler than XSD, like .NET&#8217;s common type system.  It describes types much more succinctly.  A parallel might be C++ to C: C++ is an object-oriented language with object-oriented features.  You can code C++ so that it degenerates to not being object-oriented, but you&#8217;d be missing out on a whole heckuva lot.  Now, this discussion is interesting and all, but it&#8217;s not what this post is really all about.  This was the background to set up a higher-level question that came up while I was having coffee this afternoon with Corey and Chris.</p>
<p>We&#8217;ve been beholden to a statically typed language for this entire discussion, and it has been forgotten that an entire realm of dynamically typed languages exist out there, and I believe they render the entire discussion meaningless.  Langauges like <a href="http://www.ecma-international.org/publications/standards/Ecma-262.htm">ECMAScript</a>, <a href="http://www.ruby-lang.org/en/">Ruby</a>, or <a href="http://www.python.org/">Python</a>.  Take ECMAScript, for example: It&#8217;s dynamically typed, and the concept of a class only exists in-so-much as each object is its own class.  Equality is based strictly on structure.  In such a language, the idea of a nominal type is pointless, and therefore such a language can always parse any given XML structure and create a type at runtime to represent that XML.  It doesn&#8217;t matter whether the schema validates or not as long as the XML is well-formed.  It seems to me that the robustness provided by the dynamic typing makes it a near-essential feature for writing flexible, resilient consumers and services.  Certainly it cannot be worse than requiring re-generation of some proxy classes at build time.  I am beginning to think that this entire is-it-a-type-system discussion is irrelevant in the face of languages that neither use nor require a type system.</p>
]]></content:encoded>
			<wfw:commentRss>http://ardvaark.net/xsd-as-a-type-system-redux/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
