<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>Talk Like A Duck: Category humor</title>
    <link>http://talklikeaduck.denhaven2.com/articles/category/humor</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>In Ruby, it's not the dog, it's the tricks!</description>
    <item>
      <title>Lord Love a Duck!</title>
      <description>From &lt;a href="http://frogsmoke.com/2008/06/21/w-extra-duck/"&gt;one of the many non-Ruby blogs I follow&lt;/a&gt; comes &lt;a href="http://www.flickr.com/photos/misty69/sets/72157603743580096/"&gt;this collection of strange duck-types.&lt;/a&gt;
&lt;p&gt;A bit off the beaten track for this blog, but, &amp;#8220;if it quacks&amp;#8230;!&amp;#8221;&lt;/p&gt;</description>
      <pubDate>Sat, 21 Jun 2008 08:08:00 -0400</pubDate>
      <guid isPermaLink="false">urn:uuid:3781a442-c9fc-4ecb-a2fd-913bb485fa32</guid>
      <author>Rick DeNatale</author>
      <link>http://talklikeaduck.denhaven2.com/articles/2008/06/21/lord-love-a-duck</link>
      <category>humor</category>
      <trackback:ping>http://talklikeaduck.denhaven2.com/articles/trackback/504</trackback:ping>
    </item>
    <item>
      <title>Punch Card Tales</title>
      <description>&lt;p&gt;For some reason, talk on ruby-talk brought up old computer stories.  David Black related a story told him by a former boss about a &amp;#8220;photo op&amp;#8221; in a company computer center triggering failures when the photographers&amp;#8217; flashes upset the optical sensors in the tape drives.&lt;/p&gt;


	&lt;p&gt;Since I&amp;#8217;m sitting in a hospital cafeteria this afternoon waiting to see my wife who just had some surgery. I figured I might amuse myself, and hopefully you gentle reader with some old mainframe war stories.&lt;/p&gt;


&lt;h2&gt;Tale #1&lt;/h2&gt;

	&lt;p&gt;When I was an undergraduate, I used to spend all my free-time (and much of my non-free time) at the University computer center.  There was a large room for student use with keypunch machines on the walls and worktables in the center.&lt;/p&gt;


	&lt;p&gt;One of my friends was a graduate student who was working on a team writing an Algol compiler as a term project.  They had broken down into teams, lexical analysis, parser, code generation ,etc.  They were in the middle of integration.&lt;/p&gt;


	&lt;p&gt;The &amp;#8220;source code control system&amp;#8221; was a large punch card box.  For those who haven&amp;#8217;t seen them these are long corrogated cardboard boxes which hold a &lt;b&gt;big&lt;/b&gt; stack of cards and have a lid hinged in the back.&lt;/p&gt;


	&lt;p&gt;The team was making a series of debugging runs, they would take turns carrying the box to the room with the card reader and offer the contents to the god in the mainframe as their latest &amp;#8216;sacrifice.&amp;#8217;  When the listing came back, they would spread it out on the table and figura out what to do next.&lt;/p&gt;


	&lt;p&gt;This wasn&amp;#8217;t &amp;#8216;pair&amp;#8217; programming, it was &amp;#8216;septet&amp;#8217; programming.&lt;/p&gt;


	&lt;p&gt;I was sitting at a nearby table helping another student with a homework assignment, and glancing occasionally at the compiler team.&lt;/p&gt;


	&lt;p&gt;The guy with the card box came back from the reader to see his team-mates vigoursly discussing something they had seen in the last run. He was carrying the box in front of him, his fingers wrapped around the bottom, and his thumbs holding the lid down.  He walked up to the table gaining interest in the discussion. As he leaned over the table, he absent-mindedly rotated his wrists and &lt;b&gt;relaxed his thumbs!&lt;/b&gt;&lt;/p&gt;


	&lt;p&gt;They spent the next hour or so trying to &amp;#8216;revert&amp;#8217; the deck from the last listing.&lt;/p&gt;


	&lt;p&gt;Thank God that today we&amp;#8217;ve got cheap hard-disks and subversion!&lt;/p&gt;


&lt;h2&gt;Tale #2&lt;/h2&gt;

	&lt;p&gt;Same time frame and place.&lt;/p&gt;


	&lt;p&gt;Tom was another graduate student friend.  He was an older guy who had come back to school after spending some time in the trenches in Texas. Back in the early 1970s there was lots of data processing done by what &lt;span class="caps"&gt;IBM&lt;/span&gt; called &amp;#8220;Unit Record Shops.&amp;#8221; Tome had worked in one before coming to graduate school.&lt;/p&gt;


	&lt;p&gt;In &lt;span class="caps"&gt;IBM&lt;/span&gt; parlance a punched card was a unit record since the file record (I guess we&amp;#8217;d call it a row in &lt;span class="caps"&gt;SQL&lt;/span&gt; these days) and the physical unit, the card, were one and the same.&lt;/p&gt;


	&lt;p&gt;Unit record shops, didn&amp;#8217;t have computers, which in those days were investments on the order of a million dollars, give or take an order of magnitude or two. They did everything with decks of punchcards and machines which sorted, collated, or printed them. These machines were &amp;#8216;programmed&amp;#8217; by connecting holes in plugboards with wires.&lt;/p&gt;


	&lt;p&gt;Tom said that once he&amp;#8217;d accompanied his boss to a trade show. The boss, like many others, didn&amp;#8217;t have a really good grasp of the technology his business used.&lt;/p&gt;


	&lt;p&gt;The boss saw Tom on the show floor and told him, &amp;#8220;Tom, come here, you&amp;#8217;ve &lt;b&gt;got&lt;/b&gt; to see this!&amp;#8221;&lt;/p&gt;


	&lt;p&gt;He led Tom to a booth where a &amp;#8220;booth babe&amp;#8221; was loading a rainbow-colored stack of cards into the input hopper of a machine, and pushing the start button at which point the machine put all the blue cards in one slot, the yellow cards in another, and so forth.&lt;/p&gt;


	&lt;p&gt;Tom couldn&amp;#8217;t figure out &lt;b&gt;why&lt;/b&gt; the boss was so impressed, surely he&amp;#8217;d seen sorting machines before. After all they has several of them at work.&lt;/p&gt;


Then the boss showed his hand.
&lt;blockquote&gt;
Tom, I&amp;#8217;ve seen lots of fancy machines in my day, but this is the &lt;b&gt;first&lt;/b&gt; one I&amp;#8217;ve ever seen that could sort by &lt;b&gt;color!&lt;/b&gt;
&lt;/blockquote&gt;

	&lt;p&gt;Even today, it&amp;#8217;s too easy to create demos with lots of flash and no substance.&lt;/p&gt;</description>
      <pubDate>Wed, 27 Jun 2007 17:02:00 -0400</pubDate>
      <guid isPermaLink="false">urn:uuid:b6bc2534-09b1-4377-8985-50808c2642b8</guid>
      <author>Rick DeNatale</author>
      <link>http://talklikeaduck.denhaven2.com/articles/2007/06/27/punch-card-tales</link>
      <category>war_stories</category>
      <category>humor</category>
      <trackback:ping>http://talklikeaduck.denhaven2.com/articles/trackback/436</trackback:ping>
    </item>
    <item>
      <title>Where I Come From</title>
      <description>&lt;p&gt;Maybe I&amp;#8217;ve gotten a bit sensitive of late to the perception some Rubyists
seem to have of Smalltalk-bred Rubyists like me. So I thought that I might say a bit more of what
I think of the current and future of Ruby as a language.
What follows is much longer than what I expected it to be when I started writing it yesterday,
I hope that some will find it some combination of interesting, useful, thought-provoking, or
at least amusing.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;This weeks meeting of the &lt;a href="http://ruby.meetup.com/3/"&gt;raleigh.rb&lt;/a&gt;
group was a recap of railsconf 2007. Some of the attendees seemed to have gotten 
a feeling that Avi Bryant was attacking Ruby in his keynote.  I can&amp;#8217;t speak for
him, and I wasn&amp;#8217;t there so this might just be my reaction.&lt;/li&gt;
&lt;li&gt;Heard this week on ruby-talk in a discussion of the fact that Module#ancestors doesn&amp;#8217;t
include a singleton class of the receiver should it have one:
&lt;blockquote&gt;
I do not want to argue with the wise guys if it is an error &amp;#8211; I
clearly thought so but that is not important ;)
&lt;br/&gt;&lt;br/&gt;But it really would have saved me an hour of debugging if the doc
stated clearly that singletons are not included. I thought this might
help others and as it took me 20s to vim the missing line into class.c
&lt;br/&gt;&lt;br/&gt;
- Robert Dober
&lt;/blockquote&gt;
To which I replied:
&lt;blockquote&gt;
As far as I can tell, singleton classes aren&amp;#8217;t mentioned in the doc.
The documentation borders on folklore.
&lt;br/&gt;&lt;br/&gt;
Singletons as a means of implementing both individual instance, and
class behavior have a position like &amp;#8220;the man behind the curtain&amp;#8221; in
&amp;#8220;The Wizard of OZ.&amp;#8221;  We&amp;#8217;re really supposed to disregard them. &lt;G&gt;
&lt;br/&gt;&lt;br/&gt;
Coming from a background in Smalltalk, my preference would be if this
machinery were more visible and official, but Matz has his reasons for
not doing so.  For one thing, not documenting it, and hiding it from
methods like ancestors and class makes it easier to tinker with as the
language evolves without &amp;#8220;officially&amp;#8221; breaking backward compatibility.
&lt;/blockquote&gt;
&lt;p&gt;Which prompted:
&lt;blockquote&gt;
Does that mean that no one who&amp;#8217;s ever used Smalltalk can ever think
that it&amp;#8217;s right for Ruby to deviate from Smalltalk? :-)  I ask in a
humorous spirit&amp;#8212;and also because it gives me an excuse to mention:
&lt;br/&gt;&lt;br/&gt;
&lt;a href="http://www.infoq.com/articles/coming-from-ruby"&gt;http://www.infoq.com/articles/coming-from-ruby&lt;/a&gt;
&lt;br/&gt;&lt;br/&gt;
&amp;#8212;David A. Black
&lt;/blockquote&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;To answer David&amp;#8217;s humorously posed question, &lt;strong&gt;No&lt;/strong&gt;, 
and I present myself as &amp;#8220;exhibit A,&amp;#8221; because I certainly think that it&amp;#8217;s right
for Ruby to deviate from Smalltalk.  My main motivations in writing about Ruby in the context
of my Smalltalk background are first to help myself, and I hope others, understand Ruby a little
better by providing some perspective from another, earlier, dynamic language, and second, to a much
lesser extent, to air ideas of how some of the features of Smalltalk might be incorporated or
adapted as useful additions to Ruby as it evolves.
&lt;/p&gt;
&lt;p&gt;In many ways, I like Ruby better than I like Smalltalk.  To name a few reasons, Ruby is more dynamic, has a more flexible deployment &amp;#8216;model,&amp;#8217;, and 
albeit it&amp;#8217;s not a technical reason, it&amp;#8217;s not carrying the burden of the old business model of 
trying to get thousands of bucks for each development seat.&lt;p&gt;  
&lt;p&gt;This 
is what really allowed
Java to pop Smalltalk&amp;#8217;s balloon.  Smalltalk was seen by &lt;span class="caps"&gt;IBM&lt;/span&gt; and it&amp;#8217;s competitors as &amp;#8220;enterprise&amp;#8221; 
technology, and they expected the same kind of prices which
other corporate level software development
tools commanded.  When Java came out and was free &amp;#8220;as in beer,&amp;#8221; it gained a large popularity with
language hobbyists/hackers who could easily get it to play with, and a lot of those guys worked
for the companies to which &lt;span class="caps"&gt;IBM&lt;/span&gt;, ParcPlace-Digitalk, and the others were catering.&lt;/p&gt;
&lt;p&gt;The other aspect of Java which helped at the time was it&amp;#8217;s relationship in 
syntax, and a lot of its semantics, to C++ at a time when there was a lot of corporate C++
activity and some frustration was starting to be felt with the complexity of C++.  Java
felt enough like a simplified and friendlier C++ being a language which was more dynamic
without &amp;#8220;going all the way&amp;#8221; and which
felt familiar to both C++ advocates and C++ approach to
strongly typed class hierarchies, and C++ programmers with symptoms of the
&lt;a href="http://en.wikipedia.org/wiki/Stockholm_syndrome"&gt;Stockholm syndrome.&lt;/a&gt;
These self-same aspects of Java caused many Smalltalkers to be uneasy with
the language.&lt;/p&gt;
&lt;p&gt;The real salvation of Smalltalk, as it exists today, was and is Squeak.  I remember when I
first encountered Squeak, it was at a Birds-of-a-feather session at &lt;span class="caps"&gt;OOPSLA&lt;/span&gt;, right when Java was
really starting to get most of the mind-share.  My impression was that the atmosphere in the room
must have been somewhat like that in the Roman catacombs when the early Christians were 
hiding out.&lt;/p&gt;
&lt;p&gt;I guess that there is still a bit of the old &amp;#8220;Enterprise&amp;#8221; Smalltalk market, 
Instantiations, which took
over the old &lt;span class="caps"&gt;IBM&lt;/span&gt;/VisualAge Smalltalk base when it fell out of IBMs strategies, 
&lt;a href="http://www.instantiations.com/VAST/purchase.html"&gt;
sells it for an entry price of 
$6,995.&lt;/a&gt; There must be enough of the old legacy corporate Smalltalk customers around who 
buy it.&lt;/p&gt;
&lt;p&gt;Personally, it&amp;#8217;s been quite a while since I was an active Smalltalker, I made an oddyssey
through Java-land with IBMs shift in priorities.  I plan to write about some of my 
feelings during that period in retrospection but that&amp;#8217;s for a later date.&lt;/p&gt;
&lt;p&gt;I haven&amp;#8217;t been
keeping up with Squeak enough to know how and how much it has evolved the Smalltalk technology
and community.&lt;/p&gt;
&lt;h2&gt;Old Smalltalker&amp;#8217;s perceptions of Ruby&lt;/h2&gt;
&lt;blockquote&gt;
&lt;p&gt;I always thought that Smalltalk would beat Java, I just didn&amp;#8217;t know that it would be called
&amp;#8216;Ruby&amp;#8217; when it did.&lt;/p&gt;
&lt;p&gt;&amp;#8212;Kent Beck&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;I ran across this quote for the first time a few weeks ago.  It &lt;strong&gt;sounded&lt;/strong&gt; like
something that Kent would say, and also something that I would like to quote myself, but just
to make sure, I asked him.  He told me that &amp;#8216;yes&amp;#8217; he had said it in a private communication to
someone else, and both he and the original recipient had only recently found out that it was
becoming an internet meme.  Googling &lt;a href=""I always thought smalltalk would beat java"&gt;
&amp;#8220;I always thought that Smalltalk would beat Java&amp;#8221;&lt;/a&gt; garners over 250 hits.&lt;/p&gt;
&lt;p&gt;Kent tells me that he&amp;#8217;s a Ruby fan. Ward Cunningham is also. 
&lt;p&gt;I asked Ward, just before RailsConf,
if he was going since it was in his home-town.
He said that he had found out about it after
registration was closed, but he was planning to hang out at the hotel anyway.  From what I heard
last night he was recognized and invited to attend.&lt;p/&gt;
&lt;p&gt;Several of my other old Smalltalk buddies, who had also gone through a period with Java,
seem to have the same feeling which I do, that
looking at and using Ruby feels like being a widower who meets a new woman, who just seems to 
be a partial reincarnation of the former spouse.&lt;/p&gt;
&lt;h2&gt;Where You Are Come From Depends On Where You Came From&lt;/h2&gt;
&lt;p&gt;Getting to David Black&amp;#8217;s article.  He certainly has a point about letting Ruby be Ruby.  As
I&amp;#8217;ve said, I&amp;#8217;m quite happy with Ruby.&lt;/p&gt;
&lt;p&gt;Getting back to the early perceptions of Java, and making an analogy with natural languages
let me suggest that if we think of Smalltalk as Italian, and C++ as German, Java is
&lt;a href="http://en.wikipedia.org/wiki/Alsatian_language"&gt;Alsatian&lt;/a&gt;, and Ruby is French.&lt;/p&gt;
&lt;p&gt;Were it not for Squeak, Smalltalk might be Latin instead of Italian.&lt;/p&gt;
&lt;p&gt;The most un-Smalltalk like thing about Ruby, to me at least, is the syntax, 
Smalltalk has almost
none, many Smalltalkers say that Ruby has too much. I thought so initially, but now
I&amp;#8217;d argue that the flexibility and
&amp;#8220;sugarary&amp;#8221; aspects of Rubys syntax are what makes it so successful as a host for internal DSLs
like Rake, Rails/ActiveRecord, RSpec, etc. etc.  which would be far less
natural in Smalltalk with its extremely limited syntax.&lt;/p&gt;
&lt;p&gt;One of the complaints I often
heard about Smalltalk was it&amp;#8217;s &amp;#8216;different&amp;#8217; syntax just unary, binary, and keyword message send
expressions, blocks, parentheses for expression grouping, the use of &amp;#8217;;&amp;#8217; to send a message
to the object which got the last one,
and single value assignment, and a way to return a value, everything else,
including class and method definition, and control flow was built from these atoms.&lt;/p&gt;
Ruby probably appeals to a broader audience
since it looks enough like something like Java not to be considered too wierd, at least not at
first.  For one thing in ruby 1 + 2 * 3 is 7, instead of 9 in Smalltalk due to its total lack
of operator precedence.&lt;/p&gt; 
&lt;p&gt;But, syntax differences aside, conceptually both Smalltalk and
Ruby are romance languages, as compared to the Teutonic C++ and it&amp;#8217;s kinder-gentler relative.&lt;/p&gt;
&lt;h2&gt;Language Evolution and Cross-Breeding&lt;/h2&gt;
&lt;p&gt;Programming languages evolve much like natural languages.  They pick up influences from 
other languages and incorporate them with modifications.  English is the equivalent
of a multi-paradigm language, it has been influenced by the languages spoken by both the conquered
and counquerors of English speaking lands.  It&amp;#8217;s been influenced by Vikings, Normans, and Indians (both the Asian and American meanings of the last).
English has a lot of synonym pairs one from French and
one from Anglo-Saxon with it&amp;#8217;s Germanic roots.  Pork and pig; beef and cow; fraternity and brotherhood.  This comes from the days after the Norman conquest when the language of the English court
was French.  Bill Bryson describes this in his book 
&lt;a href="http://www.amazon.com/gp/product/0380715430?ie=UTF8&amp;#38;tag=denhaven2com-20&amp;#38;linkCode=as2&amp;#38;camp=1789&amp;#38;creative=9325&amp;#38;creativeASIN=0380715430"&gt;The Mother Tongue&lt;/a&gt;&lt;img src="http://www.assoc-amazon.com/e/ir?t=denhaven2com-20&amp;#38;l=as2&amp;#38;o=1&amp;#38;a=0380715430" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /&gt;&amp;#8221;&amp;#8221;The Mother Tongue&amp;#8221;.&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;
Many of the words considered &amp;#8220;fancy&amp;#8221; by English speakers are of French origin.  Kent 
Beck told me that while he was working in Zurich on a contract with a Swiss bank, he found that
an effective way of communicating with the programmers there, was to use simple English grammar,
but &amp;#8220;fancy&amp;#8221; English vocabulary.  The latter helped because the Swiss programmers facility with 
French increased the chances that they would share such word.&lt;/p&gt;
&lt;h2&gt;Multi-lingualism&lt;/h2&gt;
&lt;p&gt;There&amp;#8217;s an old joke which goes:&lt;/p&gt;
&lt;blockquote&gt;What do you call a person who speaks two languages? 
&lt;br/&gt;Bilingual.&lt;br/&gt;&lt;br/&gt;
And what do you call someone who speaks only one language?
&lt;br/&gt;An American.
&lt;/blockquote&gt;
&lt;p&gt;Most good programmers, even the Americans, are multi-lingual when it comes to programming 
languages. As it does with natural languages, this gives a broader perspective.&lt;/p&gt;
&lt;p&gt;But multi-lingualism sometimes makes it hard to compartmentalize language concepts.  
Once on a trip to Zurich,
I was having dinner with Erich Gamma, some other Zurich OTIers, and a couple of customers in a
very nice restaurant on the Bahnhofstrasse.  My facility with German fills a small thimble, 
but as I perused the large menu, with no obvious English to be seen, I realised that I was reading
it rather easily, and thought to myself, &amp;#8220;Hmmm, I&amp;#8217;m starting to understand German.&amp;#8221;  Then I 
realized
that the menu was in fact bi-lingual, but the second language was French, a language with which I do have some facility.&lt;/p&gt;
&lt;p&gt;I suspect that the &amp;#8220;coming from x&amp;#8221; quotes in David Black&amp;#8217;s article are the result of this 
difficulty in compartmentalizing by newcomers to Ruby.&lt;/p&gt;
&lt;h2&gt;A Living Language&lt;/h2&gt;
Programming languages, like natural languages, survive best when they evolve, this is what
distinguishes live languages from dead ones. Languages die as the number of speakers diminish, 
despite revival attempts like &lt;a href="http://www.amazon.com/gp/product/014015339X?ie=UTF8&amp;#38;tag=denhaven2com-20&amp;#38;linkCode=as2&amp;#38;camp=1789&amp;#38;creative=9325&amp;#38;creativeASIN=014015339X"&gt;Winnie Ille Pu&lt;/a&gt;&lt;img src="http://www.assoc-amazon.com/e/ir?t=denhaven2com-20&amp;#38;l=as2&amp;#38;o=1&amp;#38;a=014015339X" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /&gt;, 
&lt;a href="http://www.amazon.com/gp/product/0865164207?ie=UTF8&amp;#38;tag=denhaven2com-20&amp;#38;linkCode=as2&amp;#38;camp=1789&amp;#38;creative=9325&amp;#38;creativeASIN=0865164207"&gt;Quomodo Invidiosulus Nomine Grinchus Christi Natalem Abrogaverit: How the Grinch Stole Christmas in Latin&lt;/a&gt;&lt;img src="http://www.assoc-amazon.com/e/ir?t=denhaven2com-20&amp;#38;l=as2&amp;#38;o=1&amp;#38;a=0865164207" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /&gt;,
&lt;a href="http://www.amazon.com/gp/product/1582348251?ie=UTF8&amp;#38;tag=denhaven2com-20&amp;#38;linkCode=as2&amp;#38;camp=1789&amp;#38;creative=9325&amp;#38;creativeASIN=1582348251"&gt;Harrius Potter et Philosophi Lapis (Harry Potter and the Philosopher&amp;#8217;s Stone, Latin Edition)&lt;/a&gt;&lt;img src="http://www.assoc-amazon.com/e/ir?t=denhaven2com-20&amp;#38;l=as2&amp;#38;o=1&amp;#38;a=1582348251" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /&gt;, or 
the &lt;a href="http://la.wikipedia.org/wiki/Pagina_prima"&gt;Vicipaedia&lt;/a&gt;.
&lt;p&gt;Ruby is evolving, the core-team isn&amp;#8217;t asleep, right now ruby1.9 is the cauldron to which new
potions are being added to brew what will emerge as the next major Ruby revision.&lt;/p&gt;
&lt;p&gt;This is another area where Ruby and Smalltalk have similarities. 
Smalltalk started as a paper design by Alan Kay to win
a hallway bet challenging his assertion that he 
&amp;#8220;could define the &amp;#8216;most powerful language in the world&amp;#8217; in &amp;#8216;a page of code&amp;#8217;.&amp;#8221; 
Dan Ingalls then actually implemented it in Basic on a &lt;span class="caps"&gt;NOVA&lt;/span&gt; minicomputer, this 
begat Smalltalk-72,
which begat Smalltalk-76, which begat Smalltalk-80. Smalltalk-80 was the basis for the 
commercial Smalltalks of the pre-Java era, VisualWorks Smalltalk (ParcPlaces commercial Smalltalk-80),
Smalltalk/V which merged with VisualWorks when ParcPlace and Digitalk merged, and &lt;span class="caps"&gt;IBM&lt;/span&gt;/VisualAge
Smalltalk. Squeak is also a child of Smalltalk-80.&lt;/p&gt;
&lt;p&gt;Smalltalk started to freeze when it became commercial.  We tried hard to forge a standard in
&lt;span class="caps"&gt;X3J20&lt;/span&gt; which allowed evolution and variation by underspecifying things as much as we could, but
broad enterprise acceptance slowed things down quite a bit.&lt;/p&gt;
&lt;p&gt;So it&amp;#8217;s exciting to see that Ruby is evolving. I hope that it too doesn&amp;#8217;t get bogged down
in it&amp;#8217;s success.&lt;/p&gt;
&lt;h2&gt;Personal Preferences&lt;/h2&gt;
&lt;p&gt;Finally getting back to my &amp;#8220;Coming from Smalltalk&amp;#8221; quote in ruby-talk, I expressed a personal
viewpoint that Ruby would be well-served if the mechanisms of singleton classes, and their use
as metaclasses were made visible and officially documented parts of the language.
If the rationale for not doing so is to preserve &amp;#8220;freedom-of-action&amp;#8221; in changing the
implementation in future versions, I can understand it, but to used a mixed language 
expression, that is a &amp;#8220;two-edged katana.&amp;#8221;  One of the things which Alan Kay told me a long time
ago was that he was disappointed that so few Smalltalkers experimented with changing and 
extending Smalltalk by building off of the mechanisms of Class, Metaclass, and Behavior.
In Ruby, despite the fact that knowledge of the equivalent implementation is only known 
&amp;#8220;sub-rosa,&amp;#8221; there is much more such experimentation.
Metaprogramming in Ruby is au courant, and lots of code is being written which depends on 
undocumented &amp;#8220;stuff.&amp;#8221;  I have to ask if this, being undocumented that is, is a good thing.&lt;/p&gt;
&lt;p&gt;So, to wrap this all up, while I do &amp;#8220;come from Smalltalk,&amp;#8221;  Today, I live in Ruby!&lt;/p&gt;</description>
      <pubDate>Thu, 21 Jun 2007 15:06:00 -0400</pubDate>
      <guid isPermaLink="false">urn:uuid:e9e90ebe-9145-4ff6-977c-19478dc34a92</guid>
      <author>Rick DeNatale</author>
      <link>http://talklikeaduck.denhaven2.com/articles/2007/06/21/where-i-come-from</link>
      <category>psychology</category>
      <category>ruby</category>
      <category>smalltalk</category>
      <category>humor</category>
      <category>language</category>
      <category>C</category>
      <category>java</category>
      <category>language_wars</category>
      <trackback:ping>http://talklikeaduck.denhaven2.com/articles/trackback/434</trackback:ping>
    </item>
    <item>
      <title>Money is the Root of all ..</title>
      <description>&lt;p&gt;$. Or at least implicit $&lt;/p&gt;
&lt;p&gt;Just seen on ruby-talk:&lt;/p&gt;
&lt;blockquote&gt;
|If we call gets(), the returned string is copied to a special variable $_
&lt;br/&gt;|Do we have such things for getc(), too?
&lt;br/&gt;
No, implicit global variables are evil.  I&amp;#8217;d rather remove $_ in the
future.
&lt;br/&gt;&lt;br/&gt;
matz.
&lt;/blockquote&gt;
&lt;p&gt;Maybe the reason that Matz picked $ as the sigil for global variables &lt;strong&gt;wasn&amp;#8217;t&lt;/strong&gt; to follow perl!&lt;/p&gt;
&lt;p&gt;And this just after we learn that &lt;a href="http://www.laweekly.com/news/news/ray-bradbury-fahrenheit-451-misinterpreted/16524/"&gt;&amp;#8220;Fahrenheit-451&amp;#8221;&lt;/a&gt; was about the dangers not of government censorship but of TV.&amp;#8221;</description>
      <pubDate>Tue, 05 Jun 2007 23:16:00 -0400</pubDate>
      <guid isPermaLink="false">urn:uuid:0650c377-b599-4960-b241-ab6f89b1c418</guid>
      <author>Rick DeNatale</author>
      <link>http://talklikeaduck.denhaven2.com/articles/2007/06/05/money-is-the-root-of-all</link>
      <category>ruby</category>
      <category>humor</category>
      <category>globals</category>
    </item>
    <item>
      <title>On Hunting Ducks</title>
      <description>&lt;p&gt;Five doctors go duck hunting, they draw lots to determine the order in which they will shoot from the blind.&lt;/p&gt;


	&lt;p&gt;The Psychiatrist gets the first chance.&lt;/p&gt;


	&lt;p&gt;A flock of birds fly over. He looks down at his shotgun and says&lt;/p&gt;


&lt;blockquote&gt;They look like ducks! They sound like ducks!  I wonder how they feel about being ducks?&lt;/blockquote&gt;

	&lt;p&gt;Meanwhile the birds fly by.&lt;/p&gt;


	&lt;p&gt;Next up is the internist:&lt;/p&gt;


&lt;blockquote&gt;They look like ducks! They sound like ducks!  But we can&amp;#8217;t rule out the possibility that they might be geese.&lt;/blockquote&gt;

	&lt;p&gt;Then the general practitioner:&lt;/p&gt;


&lt;blockquote&gt;They look like ducks! They sound like ducks!  What do you guys think?.&lt;/blockquote&gt;

	&lt;p&gt;The surgeon takes his place next.  He confidently feels the trigger of his shotgun with his highly skilled right forefinger. The next flock flys over.&lt;/p&gt;


&lt;blockquote&gt;&lt;b&gt;Bang!  Bang!&lt;/b&gt;&lt;/blockquote&gt;

	&lt;p&gt;And the surgeon turns to the pathologist and says:&lt;/p&gt;


&lt;blockquote&gt;Check them out and see if they are ducks.&lt;/blockquote&gt;

	&lt;p&gt;I&amp;#8217;ve known this joke for quite a few years, but I&amp;#8217;ve never thought about it in relationship to software, until I started playing around with Ruby, and discovered an old friend under a new name, &amp;#8220;Duck Typing.&amp;#8221;&lt;/p&gt;


	&lt;p&gt;Last week, I ran across a thread on the ruby forum called &lt;a href="http://www.ruby-forum.com/topic/74246"&gt;&amp;#8220;I&amp;#8217;ll have the Duck!&amp;#8221;&lt;/a&gt; which quickly got lots of responses, and seems to have ended up with jokes.&lt;/p&gt;


	&lt;p&gt;Most of this thread seems to miss the point of duck typing.&lt;/p&gt;


	&lt;p&gt;Once you&amp;#8217;ve really grokked duck-typing you become like that surgeon.  Your perception of the properties of objects that really matter changes.  And you learn to use the pathologist (testing) as a powerful ally.&lt;/p&gt;


	&lt;p&gt;Many programers coming to ruby from languages like C++ and Java are like the psychiatrist, internist, and general praticioner in the duck hunting story.&lt;/p&gt;


	&lt;p&gt;They want certainty in their typing.  They&amp;#8217;ve developed the expectation that early type-checking by a compiler will keep them from making mistakes.&lt;/p&gt;


The problem with this expectation of the power of early type checking is two-fold.
&lt;ul&gt;
&lt;li&gt;It doesn&amp;#8217;t really work&lt;/li&gt;
&lt;li&gt;It is overly constraining&lt;/li&gt;
&lt;/ul&gt;

	&lt;p&gt;It doesn&amp;#8217;t work because the bugs caused by type-checking errors is a small subset of buges in general. Besides, in a fully object&amp;#8212;oriented language like Ruby or Smalltalk, they are rare (because the methods which actually operates on the data is actually automatically strongly type-bound to the data by virtue of it being a method.  It&amp;#8217;s overly constraining because it unnecessarily couples the implementations of the provider and users of the services provided by an object.&lt;/p&gt;


	&lt;p&gt;Rather than droning on about the failures and contraints of early-type checking, which I suspect I&amp;#8217;ll address more fully here as time goes on. Allow me to introduce the notion of types in an object-oriented languagethat I&amp;#8217;ve come to accept over many years.&lt;/p&gt;


	&lt;p&gt;Let me suggest that in a fully object-oriented language types are not properties of objects or classes, but properties of variables which code using an object uses to refer to those objects.  In saying this I&amp;#8217;m recapping the key idea behind an &lt;span class="caps"&gt;IBM&lt;/span&gt; Technical Report I wrote back in 1991 entitled &amp;#8220;Types fromthe Client&amp;#8217;s Viewpoint&amp;#8221; &lt;a href="/files/TypesFromTheClientsViewpoint.PDF"&gt;Which is available here as a pdf file.&lt;/a&gt;&lt;/p&gt;


	&lt;p&gt;&amp;#8220;But wait a minute!&amp;#8221;, you say.  &amp;#8220;Aren&amp;#8217;t types for matching objects with variables, so that programmers won&amp;#8217;t  make mistakes when they manipulate the object?&amp;#8221;  To which I reply, &amp;#8220;That&amp;#8217;s not object-oriented.&amp;#8221;&lt;/p&gt;


	&lt;p&gt;Now of course many will argue with this, but I&amp;#8217;d like to revisit the &lt;b&gt;original&lt;/b&gt; conception of object-orientation, a term which was coined by Alan Kay, the inventor of Smalltalk, a language from which Ruby has borrowed a lot.&lt;/p&gt;


	&lt;p&gt;The key idea behind &amp;#8220;object-orientation&amp;#8221; a la Smalltalk and Ruby is the encapsulation of implementation behind an interface defined by a set of messages.  Kay felt that the traditional way of structuring software as programs which processed data, and the attendant separation of program and data was somthing to be avoided.  His view is that it isbetter to compose software out of components which all look like little computers, which contain and bind the programs and state together. This was a synthesis of ideas which he had seen over many years, although they had never been codified before he did it.&lt;/p&gt;


	&lt;p&gt;For an insight into Kay&amp;#8217;s thinking, have a look at the article he wrote some years ago about &lt;a href="http://www.smalltalk.org/smalltalk/TheEarlyHistoryOfSmalltalk_Abstract.html"&gt;&amp;#8220;The Early History of Smalltalk&amp;#8221;&lt;/a&gt;&lt;/p&gt;


	&lt;p&gt;Another way of looking at this idea, is that objects should be like little server machines, the exact set of services available and their implementation can vary from server to server, but clients can still use those services in isolation from those details.&lt;/p&gt;


	&lt;p&gt;In both Ruby and Smalltalk, classes and inheritance are used for &lt;b&gt;implementation&lt;/b&gt; sharing, in order to achieve economies in implementing those little computers (objects). This is not an essential feature in Kay&amp;#8217;s conception of OO. The original versions of Smalltalk had neither classes nor inheritance which were introduced in later versions.&lt;/p&gt;


	&lt;p&gt;In parallel with the evolution of Smalltalk, a family of languages based around the concept of &lt;i&gt;Abstract Data Types&lt;/i&gt; became an important Computer Science  research topic.  Abstract Data Types arranged data types into a hierarchy so as to categorize their use as a way to structure more traditional procedural programs, and they called these abstract &lt;b&gt;data types&lt;/b&gt;, classes, and the relationship between classes inheritance, so subclassing was simply a synonym for sub&lt;b&gt;typing&lt;/b&gt;.&lt;/p&gt;


	&lt;p&gt;Since, by the time Smalltalk had been made widely known by the publication of a special issue of Byte magazine devoted to Smalltalk-80 in 1981, it had added classes and inheritance, most observers mistakenly thought of classes and inheritance as essential features of the language.  One of these was Peter Wegner who wrote an influential paper &lt;a href="http://portal.acm.org/affiliated/citation.cfm?id=38823&amp;#38;dl=ACM&amp;#38;coll=ACM&amp;#38;CFID=15151515&amp;#38;CFTOKEN=6184618"&gt;Dimensions of Object based Language Design&lt;/a&gt; which was published in the proceedings of the 1987 &lt;span class="caps"&gt;OOPSLA&lt;/span&gt; conference.  In this paper, Wegner defined &amp;#8220;object-oriented&amp;#8221; languages as those cobining &amp;#8220;objects+classes+inheritance.&amp;#8221;  What he missed was that in Kay&amp;#8217;s conception of object-orientation classes and inheritance were merely implementation artifacts, and that the encapsulation of implementation within an object was the big idea which separates object-oriented languages from procedural languages, and despite the similarity in terminology, abstract-data-type languages, which presented instances of those data types as things to be manipulated from the outside, were far from object-oriented, at least as Kay conceived it.&lt;/p&gt;


	&lt;p&gt;So to wrap this up for now, duck-typing is a natural consequence of the nature of how objects with strongly encapsulated implementations should interact.  The notion of objects containing the code which manipulates them, and hiding that implementation behind a wall, through which messages are sent, is a paradigm shift with powerful consequences.  Because many so-called &amp;#8220;object oriented&amp;#8221; languages missed this paradigm shift, many of their users are uaware the power of thinking about software design from this new perspective.&lt;/p&gt;


	&lt;p&gt;I hope, that in some small way, this blog will help expose the beauty of this paradigm shift.&lt;/p&gt;</description>
      <pubDate>Wed, 26 Jul 2006 15:39:00 -0400</pubDate>
      <guid isPermaLink="false">urn:uuid:be83a184-9f5b-4ab2-97de-de47263fa986</guid>
      <author>Rick DeNatale</author>
      <link>http://talklikeaduck.denhaven2.com/articles/2006/07/26/my-favorite-duck-typing-story</link>
      <category>ruby</category>
      <category>smalltalk</category>
      <category>humor</category>
      <category>types</category>
      <category>oop</category>
      <enclosure type="application/pdf" length="6274072" url="http://talklikeaduck.denhaven2.com/files/TypesFromTheClientsViewpoint.PDF"/>
      <trackback:ping>http://talklikeaduck.denhaven2.com/articles/trackback/2</trackback:ping>
    </item>
  </channel>
</rss>
