The Source for Java Technology Collaboration
User: Password:



Bruce Tate

Bruce Tate's Blog

A little heresy

Posted by batate on July 08, 2004 at 03:54 AM | Comments (11)

In Hackers and Painers, Paul Graham of Arc fame dishes out his share of heresy. He tackles social heresy (actively seek out heresy, schools are prisons). But it's the programming heresies that interest me most.

This guy really challenges you to think. He represents Lisp as the one true language (certainly, the most powerful.) He talks about the problems with Java. He discusses a start up founded on Lisp that was much more productive than their competition, and digs a little at the Java community by saying that he wasn't worried if his competitors were putting up job postings for Java guys.

The book certainly made me think. We're in the age of heresy. You can say things today that you couldn't say five years ago. Here are a few of my favorites:

  • Stratic typing is an artificial safety net. Dynamic typing can make you much more productive.
  • Checked exceptions may have been a mistake.
  • OOP may actually hinder reuse. Layered software may be more important than OOP.
  • Maybe the bigger vendors don't have it all figured out before they ship a product. (EJB, CORBA, etc.)

And a little heresy is good for Java. Thank you, Paul.


Bookmark blog post: del.icio.us del.icio.us Digg Digg DZone DZone Furl Furl Reddit Reddit
Comments
Comments are listed in date ascending order (oldest first) | Post Comment

  • heresy? An age of heresy? Indeed, I seem to recall there being a proposed JSR for an Inquisition API, reportedly submitted by some Spanish developers... No, but seriously, what do you mean when you say that you can say things you couldn't 5 years ago? I never realized the Java community was once a suffocating, dogmatic intellectual environment. It seems to me like Paul Graham just forumulated some criticism of Java and labeled it heresy to make it sound a little more risqué than it actually is. Take your last suggestion for instance, Maybe the bigger vendors don't have it all figured out before they ship a product. (EJB, CORBA, etc.) I'd hate to think that it wasn't common knowledge (or compulsive belief) among Java developers that what emanates from companies like Sun or IBM isn't alway the Absolute Truth, or guided by divinely-inspired developing principles. Maarten

    Posted by: lotus118 on July 12, 2004 at 03:20 AM

  • Oi! Some definitions please! What do you mean by 'layered software'?? You said:
  • Stratic typing is an artificial safety net. Dynamic typing can make you much more productive. I'll assume you mean 'static'. Anyone who's spent time with other peoples 'dynamic' VB code will soon learn to love 'Option Explicit'. In a language which offers both, it is almost universally accepted wisdom that for debugging, the very first thing you do is turn off dynamic typing! With the implication that it might be faster to bang the code out, but that dynamic typing is then going to have a 'hidden' cost when you come to debugging.
  • Checked exceptions may have been a mistake. Checked exceptions are a brilliant and powerful tool... which can be misused. I take it we should eliminate any language feature that might be abused?? (Which believe it or not is actually the standard part line of those who don't like checked excptions). The other day I was tootling around with one of the well known XML parsers. It hit a misspelled closing tag, bombed out, and threw an unchecked runtime exception, and spat the dummy out onto the command line (System.out)... of course, this is for an EJB project... for which we're *not supposed to* use the command line. If I hadn't found this behaviour in testing, we would *never* have figured it out in the production system. When I consider this I stand amazed at how anyone can consider unchecked exceptions to be a good thing.
  • OOP may actually hinder reuse. Layered software may be more important than OOP. Maybe the bigger vendors don't have it all figured out before they ship a product. (EJB, CORBA, etc.) Corba sucks. EJB sucks as well, just not as much as Corba. :-) Whether OOP is worth it or not depends on whether you have a good design or not. At work I have to maintain a 14,000 line long EJB which some Indian ex-VB programmer pooped out. Do I blame OO for this travesty against nature? Do I blame Sun for letting him nest hashmaps inside other hashmaps? (Well... yes... I suppose they should have Hashmaps, because they are (on extremely rare occassions) sometimes useful, but it should be like something hidden, and that only those people who 'need to know' should be in on the secret) Do I blame the Java coding standards for not being more... forceful... because this guy chooses to uppercase the first letter of all his variables?
  • Posted by: rickcarson on July 12, 2004 at 05:52 PM

  • Oi! Some definitions please! Note to self: although the box says you can use li (list index) tags.... its a bad idea. Sorry.

    Posted by: rickcarson on July 12, 2004 at 05:53 PM

  • Paul Graham, Lisp vs Java Yahoo Store was rewritten in C++

    Posted by: sergiogarcia on July 12, 2004 at 06:00 PM

  • Hackers and Painters Personally I found 'Hackers and Painters' to be incredibly smug. Graham really hates Java, it's fit for 'drones' apparently. He also states somewhere that it's an evolutionary dead-end for programming languages. So forget C# (which is widely acknowledged to be have been hugely influenced by Java), Groovy, Jython etc.

    I think the book is heavily over-rated. My review of it is on TechBookReport (http://www.techbookreport.com).

    Posted by: pan on July 12, 2004 at 07:10 PM

  • Paul Graham, Lisp vs Java I investigated Lisp earlier in the year, and ran into Paul Graham's rantings. He seems like a nice guy, but there's some things that just don't add up. #1 He says that Lisp is 'more powerful' than Java, and yet his definition is that power = succinctness. Hence, shorter (fewer keystrokes) languages are better. I don't agree with that* #2 The Lisp program he touts (the shop for Amazon or something like that) was, I found on investigation, thrown away and subsequently rewritten in a different language (I suspect Java, but it might have been PHP or Perl or something like that). Note the similarity to the XP guys who tout the big project - which got canned because it was (to everyone else except the XP guys) a failure. Would sir like fire with that smoke? *More interestingly, PG links to a pdf which has a study of Lisp vs Java vs C++, and shows time taken, lines of code, number of bugs (I think? And other 'quality' concerns). And concludes that Lisp kicks prodigious bootay. The study is, in fact, quite compelling. What isn't clear is why Lisp wins that particular comparison... PG attributes it to Lisps (alleged) brevity. You could also interpet it in different ways, eg make some kind of remark about intelligence. You might use the study to argue that Lisp (or functional programming) is so hard that only geniuses can do it, which is why (in the study) the 'average' Lisp programmer beats the 'average' Java programmer, since Java is so easy that practically anyone can do it. Of course, that doesn't explain then why Java beat C++ - applying the same argument would lead one to believe that C++ is even easier than Java, so the average C++ programmer must be a complete moron... Hmm... I think I'll just stop there... ;-)

    Posted by: rickcarson on July 13, 2004 at 12:35 AM

  • Hackers and Painters It's definitely smug. I'll grant you that.

    Posted by: batate on July 15, 2004 at 11:07 AM

  • Oi! Some definitions please! Good counterpoints. I'm definitely leaning toward laguages that value power over safety, though.

    Posted by: batate on July 15, 2004 at 11:09 AM

  • Paul Graham, Lisp vs Java Of course, Graham was arguing that Lisp in the early stages gave them the best comeptitive advantage. It was far less important after Yahoo bought them. It's hard to argue with the results.

    Posted by: batate on July 15, 2004 at 11:10 AM

  • heresy? We seemed to drink the EJB cool aid in fairly significant numbers.

    Posted by: batate on July 15, 2004 at 06:11 PM





Powered by
Movable Type 3.01D
 Feed java.net RSS Feeds