Language Nirvana - Simon Peyton-Jones

5 minute video - from useful & unsafe and useless & safe to useful & safe

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Absolutely unimpressed

And I like Guido van Rossum's attitude so much more.

Did my bullshit detector give a false positive this time?

something from nothing

What did you manage to find objectionable in 5 minutes sofa chat and a sketch?

Who is prepared for the Nirvana?

Since Erik Meijer decribed himself as a "recovering typoholic" once on LtU one might assume the existence of a third occult path to the Nirvana. Besides this some people don't like it very much when others tell them straight into their face that their souls are condemned and they will never have access to the paradise. Remember how sensitive Lispers are about this issue. It was just new to me that Pythonistas would rebell as well because I always considered them as atheists with a sense for the absurdity of life.

not objectionable

but some folks (no matter how smart) talking about what they are *going* to do is simply not enough to get excited at all. I mean more or less they say that they will create programming language nirvana, right? And they are half-serious about that, aren't they?

I haven't seen the video

I haven't seen the video yet, so I can't comment about that, but after a little while in this field you tend to take SPJ seriously...

It may be more worthwhile to check the discussions of his papers in the archive than to criticize the video (especially if it's as bad as you say it is).

venn diagrams, pithy marketing overview

Ehud Lamm: I haven't seen the video yet...

I only caught the audio (because my mp3 player didn't feel like showing video) which was low in substance even when reviewing a transcript from memory. I can give a summary with most of the flavor. SPJ must have drawn two Venn diagrams of circles denoting safe and useful (and perhaps another I didn't hear emphasized), then said most useful languages fall in the unsafe area, but Nirvana would fall in the safe and useful intersection, implying his cohort was in pursuit.

In passing, SPJ mentioned there was a lot of cross fertilization between languages, but unless this was substantiated further by a diagram, I didn't catch any actual propositions or opinions — just a wish to disavow divine creation in isolation by his team. A digression toward the end on comprehensions claimed this was a geek term deriving from Haskell. (I'm glossing over contributions from Butler Lampson and others.)

In the middle was a little exposition by SPJ on the difference between shared mutable state concurrency and safe message passing, which is familiar to us. At one point he noted languages providing safe features are usually embedded in an unsafe language runtime, which sounded like a talking point that would return. Apologies if I omitted something else of interest.

If the encounter was truly unplanned and spontaneous, SPJ is an articulate and charismatic speaker with the presence of a professional actor, with marvelous clarity of diction fun to hear, and skill in speaking more slowly to avoid interruption when someone speaks at the same time, so he needn't ever yield the floor unless it suits him. (I hope my description's not too colorful.)

Erasmus

Ehud Lamm: I haven't seen the video yet, so I can't comment about that,...
McCusker: I only caught the audio...

"In the land of the blind, the one-eyed man is king."

I particularly enjoyed the summary of unseen sketches :-)

Quite possibly - it was an

Quite possibly - it was an extremely general overview of the direction in which things've been going in Haskell and of the cross-fertilisation of ideas between Haskell and "the rest of the world", so you're missing all the technical details and if you're not already a Haskeller you quite possibly don't know enough to recognise what's definitely not bullshit and has in fact been established practice for years.

Thanks, this makes better

Thanks, this makes better sense than what I concluded from their brief explanations.

Oh, this is creepy!

Oh, thats creepy! Here I am working on language wich I call Nirvana and then I find this video with Simon Peyton-Jones and Erik Meijer talking about my language, by name, no less.

I can see three explanations:

1. The idea of my language has traveled the world as an underground meme.

2. Simon Peyton-Jones is spying on me.

3. I am in fact Simon Peyton-Jones.

I favor explanation 2.

I favor explanation 2. Clearly, no single human can be as smart as SPJ. It is quite obvious that early in his career, he must have developed a means of spying on anyone in the world, perhaps by hijacking NSA spy satellites, or the secret world government spy feed from our TV sets. I'm pretty sure he controls this global spy network from an underground lair somewhere, perhaps beneath Microsoft Research in Cambridge, which he uses as a base of operations for tackling The Awkward Squad, a group of supervillains who are his eternal nemesis.

Little does he know that

Little does he know that Lambda The Ultimate is on to his game!

Fourth possibility

SPJ is from the future, having returned to present day by means of a Time Turner. If my suspicions are confirmed, the outlook for Nirvana is quite good - but I'm afraid that a lot of other programming languages will have to die an excruciating death before it's all over.

(Note: This insight was gained by the many hours spent in queue late last night - whilst awaiting the arrival of the much anticipated Programming in Erlang book - my daughter ended up buying some other book).

Fifth possibility

Reading between the lines of the parent post: SPJ is a wizard!

It's not so much that SPJ is

It's not so much that SPJ is from the future as that our present is only now being evaluated to form what SPJ has already finished.

As always I have my doubts.

As always I have my doubts. The Nirvana that is in the future is not the Nirvana. The Nirvana that is NOW is the Nirvana. But be aware about the wrong Nirvana. It is a fallacy and it is called Blub. Many novices believe they are already there and learn something that makes them believe to collapse the future into the present. They are all falling into Blub.

Meh...

The context in which I'm familiar with the term "Blub" is from Paul Graham's writing, in which Blub adherents can't make sense of Lisp because of the expressive power of Lisp constructs that simply don't exist in Blub. The problem with this (as with, frankly, most of Paul Graham's non-expository writing on Lisp) is that it presupposes that Lisp is at the most-powerful-possible end of the power spectrum—that is, that there's nothing "more powerful" than Lisp, for whatever set of measures you care to apply. I can tell you from personal experience that this is false, for any set of measures you care to name that aren't isomorphic to "being Lisp" (indeed, I would argue that the entirety of this thread between Rainer Joswig—a gifted expositor of Common Lisp development—and myself exemplifies the point in spades).

However, I understand that you merely used a word invented by Paul Graham, perhaps not with exactly the same connotations, so let's generalize a bit. Saying that "The Nirvana that is NOW is the Nirvana" might be good Buddhism (although I seriously doubt it, just as I doubt that "My karma ran over your dogma" is good Buddhism), but if taken seriously as a principle of PLT, then we might as well all hang up our compilers and go home, since this is, apparently and tragically, as good as it gets. And let's not even get into the breathtaking arrogance (and I know a thing or two about "breathtaking arrogance") of "Many novices believe they are already there and learn something that makes them believe to collapse the future into the present. They are all falling into Blub." As little as I like arguments from authority, I have to believe, based on your previous contributions here, that you don't really mean to imply that Simon Peyton-Jones is a novice whose work on PLT, STM generally, and Haskell specifically, is fallacious and leads to Blub, where Blub is understood to be something not worth using in general, and specifically not worth using relative to Lisp. So I confess to being a bit unsure as to what you actually meant. Certainly, one can spend a lifetime in the ivory tower of programming language design and never actually ship a language that people use. Haskell has a better excuse than most, being intended as a research vehicle, but it's escaped the lab and people actually use it. Perhaps an even better example is Scala, with its emphasis on pragmatically running on the JVM and interfacing with Java libraries, despite being just as hardcore a PLT-driven language as Haskell. Or one can throw up one's hands, say that Lisp already solved all problems (or Ruby, or Python, or...) and contentedly write code. But I think most people here understand that the ivory tower is a bit confining—even the ones who do use Haskell (hi, Phillipa!)—but don't accept that we should all just settle for an existing language—including, but by no means limited to, Lisp. Personally, I'd like to see Lisp in whatever form evolve (if anything, faster, please) because I still have friends in that community. But I want more expressive power and more safety. Haskell's not it for me, probably for the same reasons it's not it for most people. OCaml sits at a local optimum for me for now, with Scala on my radar for things OCaml doesn't seem appropriate for, but I can't help but hope that, yes, in the future, a new local optimum will be found. That's all.

—even the ones who do use

—even the ones who do use Haskell (hi, Phillipa!)—

I think you mean Philippa. I believe Phillipa is the one from an alternate universe, who has a beard[*] and programs in BASIC, using only gotos for control flow.

[*] As is traditional for counterparts in alternate universes, and having no connection to gender.

Indeed!

And in some other alternate universe, Paul Snively knows how to spell people's names.

Mind if I snag this for my

Mind if I snag this for my .sig collection?

Please do

You're welcome to it.

Paul, Blub and Nirvana are

Paul, Blub and Nirvana are not realities but mindests. This has little to do with Lisp vs Haskell although it originated within the context of PGs Lisp advocation phase. When you point to something and say "that's Nirvana" you can be sure it's Blub.

Aha!

So your point was that Nirvana is always the Next Big Thing, which, like Tomorrow, is always a day away. OK, I can see that. But hopefully you can see from SPJ's video that that's just a convenient label to attach to the destination that he sees not just his own research aiming for on the basis of theory, but many other languages aiming for on the basis of experience. Indeed, a big part of the video's appeal that several other people have commented on is SPJ's essential humility. He doesn't claim that Haskell has any exclusive claims here, talks about Haskell's "embarrassing problem," and cross-pollination between the two trend-lines. So I don't think SPJ's falling into the trap that I think you've nicely identified. The "Next Big Thing" is indeed always a d[ay|ecade] away when you don't know what it is. When you start with a useful theory, it constrains the destination to something a lot more tangible than that. Likewise when you look at the experience of the entire programming community. Now, SPJ might still be overly optimistic that those two trend lines will indeed converge, but if they do, doesn't it mean, by definition, that the result is "better," in some market-driven sense, than everything (as always, to a first approximation) that came before? If so, why is "Nirvana" an unreasonable humorous name for that?

Hubris in naming

If so, why is "Nirvana" an unreasonable humorous name for that?

As an amusing lesson in such name choices, there was once a heavily-marketed application generator named "The Last One", which generated BASIC code for every major desktop platform of the time (Tandy, Apple II, Commodore, CP/M). Here's a post-mortem from a 1996 DBMS magazine article:

[Circa 1980], a short-lived British company (the name of which escapes me now[*]) marketed an automatic application generator named "The Last One." The company gave it that name because it claimed the program was the last you would ever have to buy. If you had The Last One, it would create any applications you needed from then on. Alas, The Last One is no longer with us. It was not the last one.

[*] The company name was D.J.'AI' Systems, which sank from its brief marketing-driven international prominence back into obscurity once it became apparent that The Last One, wasn't. Ironically, The Last One ultimately evolved into a successor named TLO Code Utilities for Delphi.

Of course, marketing dictates that you cannot name a product "The Penultimate One", since that will just cause customers to wait for the release of The Last One. Which perversely confirms Kay's point that Nirvana must be now — marketing requires it. (May not be the true Nirvana. Void where prohibited by law.)

When I watched the video I

When I watched the video I didn't get the opinion that he was talking about a particular language called "Nirvana" or anything like that, but rather that the direction that a lot of major languages are headed are the "Safe and Useful" region of his chart. Then he just pointed out that most mainstream languages started at useful and unsafe and were heading towards safe, where as Haskell started at Safe and Useless (no/incredibly awkward IO), and is heading towards useful. I guess it's not so important, but I think what he was trying to point out that a lot of more main stream languages/families are all heading in the same direction, just from different starting points, but also kind of helping each other by producing unique ideas along the way.

Though I tend to disagree that Safe&Useful is necessarily where all the languages are going to decide is Nirvana and hang out there. Most scripting languages aren't exactly safe, and neither are some of major languages which many people know and love (lisp/smalltalk/etc). This is not to say that I don't like Safe languages, just that it's not always the top thing on my list of requirements when deciding which language to use for a particular task.

Temporal relativity of Nirvana

When I watched the video I didn't get the opinion that he was talking about a particular language called "Nirvana"

Oh, I know. But I think some historical perspective on what once might have seemed like "Nirvana" is useful. What will SPJ's idea of language nirvana seem like in hindsight, on LtU's 20th birthday, for example? And what will the new nirvana be then?

(Aside: since this discussion raises the question of what "nirvana" means, projecting a simple definition of the term onto programming languages, it implies cessation of desire for language features that we don't already have. One way to achieve this might be with a language that has all the features we could want, and leaves nothing to be desired. But studying programming languages teaches us that tradeoffs are unavoidable, so this nirvana is only reachable if you can find programming languages whose tradeoffs and limitations you can accept, or learn to accept.)

Though I tend to disagree that Safe&Useful is necessarily where all the languages are going to decide is Nirvana and hang out there. Most scripting languages aren't exactly safe, and neither are some of major languages which many people know and love (lisp/smalltalk/etc).

That's probably fodder for a long discussion about whether the benefits of the Safe&Useful nirvana can be brought to those languages, or whether all their good features can't be assimilated by the Safe&Useful languages.

From Nirvana to Paradise

If we want to spin this even further I guess one has to decouple the idea of delay from Nirvana again. Of course the mystical Nirvana has no name and cannot be told but what causes eternal delay and eternal progress is the Paradise.

The Paradise is a nostalgic lost and found fantasy. The loss is just a mythical explanation of our current misery ( the eternal software crisis and the crisis of our technical society ) and Lisp is placed well in the mythical position of the loss, the broken archaic unity. More important is the Paradise beyond the end of our times, we are dedicated to strive for in a dialectical process. Future makes sense only with regards to this expectation. Peacefull calmness supersedes our ongoing language wars and finally our minds are united with themselves again.

The mythical history is always also one that reflects fall in the presence of the evolution of civilication. The ancients were mighty poets, equipped with the raw power of their minds but hardly grasped themselves and never survived in an upscaling complex society with all its role differences, labour division and marketplaces of opinion.

Back to programming. Haskell represents the most advanced state of conscientous decisions among programming languages that have become popular at the price of all the type jugglings some people love and others hate. In the mythical scheme it represents a great division and not the closest approach to a re-found unity. And here all the abilities and undeniable rewards of SPJ don't help right now. Can it be the right thing in the presence of strong resistences?

I stop commenting now. It was fun and everyone might invent his/her own plot. It can be pluralist or monist. It can be nostalgic or just Blub ( Blub is the attitude of the pharisee in the mythic tale ).

Limiting effects

MMUs seem to be the biggest success in controlling effects of programs. I really appreciate the simplicity of the mechanism in comparison to advanced type systems. I wonder if we should be making more use of such things?

Three points...

First, I wrote code for the MMU in early Macintosh II hardware—the IIx, if memory serves me correctly—and it was anything but easy, and this was at a stage of my life when I was an expert 680x0 assembly-language programmer, working on the TMON debugger at ICOM Simulations.

Second, MMUs work at some page-size granularity; if you want to control effects at finer granularity, you still have to write some code to examine the entrails of the page-fault exception, and you're right back where you started; it's just that instead of dealing with a 4G address space, you're dealing with a 4K address space. :-)

Finally, MMU memory-mapping tends to be a relatively simple yes/no affair when it comes to effects: you can either write to an address or you can't. Sophisticated type and effect systems can provide a vastly richer context than this: values that can only be modified once; values that can only be modified after some other value has been modified...

Finer MMU granularity

There are CPUs with finer MMU granularity than 4K pages. The Infineon TriCore microcontroller, for example, allows the programmer to define four independent memory protection regions of almost arbitrary size. In the OS we (at the company I work for) use for embedded developments (PXROS-HR by HighTec), these regions are used to implement safe zero-copy message-passing between tasks.

Bullshit Lovers

:(
1 - You can, you'v done;have fun; no matter; who cares! (ie I never try to speak with a zealot. They are just after bullshit smell and they think everything in this world smells like it except themselves!)

:|
2 - I think a basic experience with Haskell is useful. This has been spoken of, in many ways to bring proven academic techniques to work. It works well; like in Ruby (Lisp, Smalltalk), F# (OCaml, Scheme), Scala (Java, ML) and this is evolution; as Java/C# class of things was natural result of growing C++ after thousands and millions lines.
So the new things that are coming along as hardwares and softwares evolve are useful discoveries based on many people's experiences; even if a single person accumulates the result, he is standing on other's shoulders.
Nirvana language is a concept here that is used to showing the direction (not the target; I think you are agree with me the most stupid person is who think has all answers in this world). Most of the power of Ruby comes from its functional powers. It about is to replace statements with expressions; so you can construct code instead of writing code.
I can say "my grand-grand-pa was so powerful to be able to dominate 20 person in a public match"! But you know ... things always change. The new things should come to help. Some may prove'em to be useful and some may disappear in a couple of month.
:)

To the extent I can understand this...

... I think I basically agree: what's often lost in discussions about why to point in a particular language-design direction, e.g. favoring static typing with a powerful type system, is the observation that you have to shoot for the moon in order to have a good chance of hitting, say, Paris (or insert lovely city of your choice). After all, if all we were saying were "Use a language with a really powerful type system," and that were sufficient, we'd all see the light and do our programming in Coq, Qi, Cayenne, or Epigram. So clearly there's a "bringing things back down to earth" phase that's needed—a making practical of the likes of Coq, Qi, Cayenne, Epigram, etc. That's why we're here.

Coq on Earth?

Maybe it would be only useful along the lines of Praxis ADA, but gosh I think it would be neat to get really good at using Coq to generate real programs. It would be neat to have the time / energy to learn and use and know really where we're at with formal methods, what the options are, what the spectrum is, and be some place where folks wanted to leverage that kind of attention to detail to avoid bugs down the road. (Heck, just having a "real" type system instead of Java/C# would probably be nice, once I got over the learning curve.)

In general, is there hope of applying theory to magically make formal methods more automatic, so there's less finger typing? So that 100 years hence our languages are checking all sorts of good things for us w/out as much work on our part as required today?

Excellent Question

I would pay attention to Matthieu Sozeau's work on Russell. I'm also encouraged by Charles Stewart's post on Theorem proving support in programming language semantics. My overall sense of excitement about the prospects can be found here.