Beyond Java - Bruce Tate [90]
Steve Yegge: Perl, Lisp, PHP, and Smalltalk
Why won't Perl replace Java?
SY: Well, I'd say Perl was pretty darn successful, and it's still one of the most popular languages around. Perl had world-class marketing: Larry Wall understands programmers, and he's funny and articulate. Perl filled a desperate niche in the Unix-scripting world, and another with CGI. Perl was successful because it was executed superbly, just as Java was.
I do think it's on the wane, though. Perl used to be more productive than the alternatives, so you could argue it was ugly all you wanted, but people got their jobs done faster. But newer languages, Ruby in particular, are changing the game.
Perl is the all-time king of pointless abstractions, like references and typeglobs, one-off shortcuts, and plain old gross hacks, with extra syntax sprayed on to cover the smell. It was productive, but programmers will take the path of least resistance, and Ruby offers orders of magnitude less friction.
What about Lisp ?
SY: That's a tough one. Lisp has world-class survival skills. People keep reinventing or rediscovering it, but Lisp is also a family of families of mutually incompatible designs and implementations, and none of the existing ones looks like a sure winner. For example, Common Lisp needs an overhaul, but redesign by committee is exactly the wrong thing for CL at this point. Lisp needs a benevolent dictator with good instincts, great execution, and great marketing.
And PHP?
SY: PHP's very popular, and getting more so, because it makes web programming easier than most of the alternatives, but Ruby on Rails is going to change all that. There will be a simplification pass to web programming at some point. PHP's not driving a simplification pass of the Web. It just tries to help you cope with the existing complexity. The language is heavily weighed down by its Perl legacy, with lots of confusing and regrettable design decisions. And it's not in the same league as more powerful languages like Ruby, Python, and Lisp.
Is Smalltalk next?
SY: I doubt it. In the end, languages have to have buzz and momentum, and I just don't see any marketing for Smalltalk. The community got the wind knocked out of it by Java, and it doesn't seem to have ever recovered.
PHP
PHP is an open source scripting language that's been gathering momentum since the early 2000s. It's a markup language that's designed to be embedded into HTML. It's very easy to quickly develop simple web applications in PHP, but those applications typically have little back-end structure. For these reasons, it's not really targeting the same niche as Java applications, though it's sometimes been pressed into service in much the same way. Here is "Hello, World" in PHP:
Hello World
'; ?>Web programmers recognize this as an HTML scripting language. The code is processed on the server side, so pure HTML can be sent down to the client. It actually handles this kind of scripting pretty well, but it's purely a tag language. PHP's problem is the structure behind the view. It's possible to use PHP for layers behind the view, but it's awkward and cumbersome in that role.
PHP is going to make some serious noise as a pure web-based scripting language, though. In one of the strangest moves in 2005, IBM announced support for PHP. This move undoubtedly targeted the small and medium-size businesses that tend to embrace PHP. IBM can now theoretically sell them software and services to round out their implementations. PHP seems to be a natural language for those Visual Basic users who don't want to make the move