## Examples of large-scale functional language projects

Could anyone point to me to real-world examples of large-scale projects (10+ developers, multi-year, 1M+ lines of code etc.) that have been developed in a functional programming language? A frequent argument that I hear is that while imperative languages are more verbose, less elegant etc., they have some intrinsic merit for the development of large projects. The argument goes that this verbosity in some way makes for code that is more maintainable / shareable amongst large groups of developers. I'd be interested in practical examples that point to the success of functional languages for similar large projects. I'm aware of some of the Erlang success stories; can anyone else share relevant ones for languages like ML, Lisp, Haskell etc?

## Comment viewing options

### ITA

One that surprised me recently was that ITA (priceline etc type sites rely on them) is largely Lisp based. I'm curious about the learning curve for new developers in such a setup.

### Naughty Dog games is the other lisp one

They supposedly used as much as 900,000 lines of code.

http://c2.com/cgi/wiki?LispInJakAndDaxter

### Lisp yes, functional no

Naughty Dog wrote their own compiler (in Common Lisp) for a custom game development language (GOAL). GOAL is decidedly imperative and OOP and can be very low level (dealing directly with the PlayStation 2 hardware). I would not use it as an example of functional programming any more than I'd use Python or Forth code as such an example.

Is the compiler itself written in a functional style? Don't know.

### Lisp yes, functional no

Most larger Lisp apps are not really that 'functional', even if we allow the term to include mostly functional languages with side-effects.

An example is the Cyc system which is under development since more than twenty years. It uses a 'frame language' called CycL on top of Lisp (or C). So, I would not really say that it is written in a functional style. Cyc provides a 'knowledge base' with more than 100000 concepts and more than 2.5 million facts and rules written in CycL.

I guess Lisp compilers written in Lisp could count as more functional programs. Some are under active development for a long time (20+ years) and have ports to 10+ platforms.

Another example for a mostly functional program might be Axiom (recently forked as FriCAS and OpenAxiom). It is a computer algebra system, but with a functional language with an interesting type system. It uses Common Lisp for its runtime. Axiom is under development since 1973 (!) and has gone through all kinds of changes. There is also another programming language (Aldor) for it, which usually does not use Lisp. Originally Axiom has been developed by IBM research. Recently at least one forked version (FriCAS) has been ported to several Common Lisp implementations. It has a quite interesting and large manual (PDF).

### Axiom kind of like ML

Axiom's language, AFAIK, is kind of like ML, but specialized to the mathematical domain. It differs a lot from Maxima (the other large CAS written in Lisp) in that respect.
Big, big project. Used to be a commercial product (CAS) from IBM but I believe the PC market - and the cheap (as in cost) Mathematica - pushed it aside (it was mainly for workstations, I believe).
Has lofty goals. A language with which one could write one's Algebra papers in it - sort of like literate programming, but for Maths. EDIT: business-friendly license too, unlike Maxima (which uses the GPL). I suppose there could be a Real World (TM) use for this in some other software that needed such advanced functionality (even though here and there it's behind the curve when compared to the traditional proprietary CAS packages). Suffers of some linuxisms last I looked (compiling "everywhere" is/was not easy).

### Cleartrip

The new-ish Indian online travel portal, cleartrip.com is built almost entirely using ANSI Common Lisp.

### GOSUB - since you seem to

GOSUB - since you seem to have registered just a while back, I guess you work for Cleartrip. No?

### Yes

Mr. Srikumar, you guessed it right :)

### Streamtech

In the summer I was at the office of Streamtech for a Lisp meeting.

They've got about ten programmers hacking Common Lisp at the moment, if I counted right. Most of which quite young. It was a really cool experience to feel the atmosphere. Lisp books lying around everywhere, guys (no girls) coming from other languages having to adopt to Common Lisp. A bit surreal in this day and age. I didn't register any complaints from them about the language, but then again we were at a Lisp meeting.

Streamtech started off doing web sites, in PHP i believe, till one of the owners discovered Common Lisp about five years ago and they decided to switch for most of their work. They're now pointing their arrows to online advertising. See their site.

### Skydeck

In case you haven't been checking your gmail recently, Mike Wells et al have been posting gmail ads looking for fp/OCaml programmers for SF based mobile startup Skydeck. At least one ex-CMUer there, so it's not that much of a surprise :) There is a definite presence of startup folk at BayFP talks, so I wouldn't be surprised if there are more such startups in the area.

### Success? Useful?

I don't really understand the question. I thought programming was supposed to be fun and coding with functional languages is just that ;-)

If you require 1M+ lines and 10+ developers, and leaving research labs at a few big software companies, you are almost abound to include developers not being either formally trained or very experienced with formal systems. Functional languages tend to abstract (almost literally) away such individuals. Read: the cognitive distance between the formal constructs and actual character or pixel changes on screen is simply too large.

What we do see is that functional programming is entering the scene through Pythonesque and Rubyesque idioms, where they even explicitly mention closures. Would that count? Then we just have to chase big RoR systems having a lot of closure/block uses.

Ok, I admittedly avoided a direct answer to your question. Sorry for that, and can just end with the fact that success is relative; for some people, having fun is the success ;-)

### Industrial use of ML

Flying Frog Consultancy are a consultancy, book and software company specializing in the ML family of languages, primarily OCaml and F#. We have product lines including books and on-line magazines teaching OCaml and F# as well as software written in or for these languages. We recently committed to writing a new book on Scala and a business management report on the use of functional programming in industry.

Microsoft have a considerable investment in the ML family of languages. Their driver verification software is written in OCaml. One of their highest profile new .NET languages, called F#, is a CAML derivative that they are already making great use of internally. For example, Microsoft trust the $2bn advertising market on MSN Live to F# code. Intel also make significant use of OCaml for hardware verification. Canon, Philips, Boeing, Sun and various other large companies are among our customers, all of whom use OCaml in industry. We also have dozens of smaller companies among our customers including XenSource, whose value-add over the free edition of Xen is largely a distributed, cross-platform, multi-programming-language management tool stack written in OCaml. They recently sold to Citrix for$500M.

Jane St. Capital have over 20 functional programmers working in offices around the world on finance. They recently expanded with a new office in London. Several other financial houses use functional programming languages extensively. Outside ML, Haskell is also popular in the financial sector following a seminal paper by Simon Peyton-Jones.

Lisp has a steady use in industry but generally for small-scale applications like shopping carts for websites. I am not aware of any uses of Lisp in billion-dollar markets.

The use of CAML-derivatives in industry (primarily OCaml and F#) continues to grow at an astonishing rate. I believe these languages are by far the most commonly used general-purpose functional programming languages in industry.

Finally, don't forget that JavaScript is a functional programming language!

### Jane Street

We have more like a dozen or so "real" programmers- we have ~80 people who write code, but most of those are traders, not programmers. Although we do have several hundred thousand lines of Ocaml code written, over the course of several years. Enough to know that the benefits of functional programming to large projects are not just hype.

### Wow.

I'd be interested to hear what the traders have to say about OCaml. I find it intriguing that people who aren't professional software developers are using it. Although I guess Mr. Minsky did say that partners review every line of code in the CUFP presentation.

### Small correction

Brian is a little closer. We actually have more than 20 people who spend a large fraction of their time programming in ocaml. That's not counting the occasional trader who does some hacking here and there or the partners who do code review.

### Are traders writing their stuff in OCaml ?

Are any of the traders using OCaml for, e.g., modelling derivates or do they use C++ ? If not, do you think it's because they're used to C++ (habit) ? Could you comment on that, please, as I'm interested in OCaml for mathematical models (instead of the usual C/C++/Fortran).

### The other functional language

I would imagine they use spreadsheets

### I meant quants

Of course, you answered that because I actually meant quants. But now, thinking about it, actually, I don't know...don't some traders write their own models (e.g., do their own time series analysis, etc.)?

All the books I have mention C++ for the number crunching...Not spreadsheets.

### APL and friends?

APL and its newer offspring like J and K did see some significant use in the financial sphere.

### Right. As far as I remember

Right. As far as I remember there were many stories about APL and ilk in the insurance world, often used by financial analysts, not people with "programmer" in their job titles.

I am not sure how true this is today, though.

### APL

I believe APL is alive and well in industry though I cannot quantify how widely used it is. Some proponents of APL have expressed an interest in our OCaml work.

### Arthur Whitney's legacy

There is an aging infrastructure of A+ at the large investment bank where Arthur Whitney was employed and where he had created A+. At one given point a small group (dozen or so) were supporting a business that is now probably being serviced by hundreds of programmers in your run-of-the-mill languages.

k and kdb+ is A+'s phoenix, and it is used for a niche market to provide time series analysis that poses too many problems for traditional relational databases.

### You seem to know a lot about

I think this story is an interesting aspect of computing history on which nothing substantial was ever written, as far as I know. Any more information will be appreciated!

### APL/J/K: Well-kept secrets

These languages definitely get less exposure than they should, there are many thousands of active developers and billions of dollars of business relying on the technologies. One important reason why you hear so little about them is that the users of languages like APL often don't think of themselved as "programmers". They are actuaries, chemical or electrical engineers, traders, etc. Most of them have no idea how they would express themselves on a forum like "Lambda the Ultimate".

Many APL vendors were very slow to adapt to the death of the mainframe, and have been very quiet for the last 2 decades. But today, excellent workstation versions exist, som even support object orientated programming, with interesting syntax for dealing with arrays of objects - and the market is recovering.

For an idea of what sort of work APL vendors are working on, see http://www.dyalog.com/version12.html or http://www.dyalog.com/help. Free educational and low-cost "non-commercial" versions are available from http://www.dyalog.com/download-zone.htm. The "array language community" also has a community web page at http://vector.org.uk.

Disclosure: The company I work for is a leading vendor of APL language systems.

### Thanks. I followed the APL/J

Thanks. I followed the APL/J world closely a decade ago, but I lost touch.
You may be right about APL developers, but surely people building APL implementations (or of other languages in the family) are developers, indeed are programming languages implementors, so they should be (should become?) part of the wider PLT community.

### APL "programming"

Indeed they should, and making that connection is one of the jobs that we, as modern APL vendors, need to take seriously: Educating APL Developers so they know that when asked at by a "real programmer" what they do, they can say things like "I use a agile methodologies to write embedded domain specific notations for financial planning", rather than "Er... what's a methodology" :-).

Modern platforms really require the ability to use platform components. To the typical APLer this is not necessarily a clear step forward, although the availability of libraries seems such a clear win to the professional programmer. This is one reason why languages like APL have struggled a bit in the 80s&90's: The libraries and platforms have been a bit too hard to use for the last couple of decades and been beyond the grasp of the typical APL user, who does not have the necessary background. Vendors scrambled to put APL-like wrappers on constantly changing API's and often did a poor job. On the other hand, the professional programmer is not much better off, he doesn't grasp the subject matter and can't the the functionality quite right (the original intent having lost in the chinese whispering game called "analysis and design"). He IS able to quickly create a web page to edit header/details in beautiful technocolor and a "rich user experience", of course!

The good news is that platforms like Microsoft.Net are significantly easier to make palatable to APLers. There is of course a quarter of a million miles of documentation of framework classes to deal with, but Google helps :-).

Connecting APLers to the PLT community remains hard. The most productive / successful APLers tend to have a non-programming background, and (naturally) only care about cracking the next financial or technical problem. Givin that this "problem focus" is right at the heart of WHY the selected a tool like APL, changing their focus is perhaps not really something you want to do. If they wanted to hang out with programmers they would NEVER have gone against the tide and selected a "unpopular" tool like APL. You could almost say they picked APL because they "don't like programming"...

Of course, there ARE "professional APL programmers" who focus on bridging "the gap between APL and IT". And the APL vendors have the responsibility to do as you say. But APL vendors have tended to recruit from within the ranks of users, and often fall prey to the same "us and them" relationship with the rest of the IT community.

"APL - possibly the most unfortunately named programming language in the world (TM)."

There has been a new management team at Dyalog for nearly 3 years now and this is one of the key issues we know we must address. I made a small start this year by submitting a paper to the DLS at OOPSLA this year to talk about work we have done on arrays of objects. We have a long way to go yet, but the market trends really do seem to favour a resurgence of APL-style technology, so we think you'll be seeing much more from this community in the decade(s) to come.

### Still do

I don't know why APL/J/K are referred to in the past tense. Kx at least is doing very well and its roster of customers is constantly expanding. The other APL companies don't seem to be hurting either: they are still around, there are still user conferences etc. However K (the language) is no longer a product and they only sell Kdb (the db), in which the user is "shielded" from K by an SQLish front-end. Thus whether that still counts as functional win is a toss.

And yes, I haven't known those days myself (too young) but I heard plenty of stories of APL being picked up by non-programmers, often people who wanted to bypass the "official" IT department and just get summit done, dammit, on their own terms. But you should keep in mind that APL doesn't have all the conceptual baggage of modern FPLs and has a simple syntax to boot.

### The past tense "did" is incorrect

APL is alive and well. Anyone who works with mortgages in large volumes will know a product called CAS which is written in Dyalog APL

This application has a rich user expression language based on vector operations that is easy for non-technical people to pick up and use.

### Lisp

Lisp has a steady use in industry but generally for small-scale applications like shopping carts for websites. I am not aware of any uses of Lisp in billion-dollar markets.

One such market already mentioned is travel (ITA).
Franz's list of success stories for their Common Lisp implementation is quite comprehensive (note the categories in the sidebar, not just the recent cases).

### Lisp in Industry

Thanks for posting the links but I can't find anything either recent or significant among them. ITA don't say what exactly they're using Lisp for. Franz have a huge list of ancient projects. Their "recent stories" are mostly years out of date and include Naughty Dog (who ditched Lisp almost 3 years ago AFAIK), art software called AARON with no mention of Lisp, a reference to the Lord of the Rings that also doesn't mention Lisp, a biotech called Symyx who don't mention Lisp, another biotech called GenWorks that do link to Franz but have no shop or product testimonials, middleware from Planisware that doesn't mention Lisp and the rest are all non-commercial academic research projects. Among all that, the only thing of any significance is the implication that Lisp is being used to some extent for airline tickets somewhere. I've no idea where, by whom or to what extent though.

In contrast, if you look for recent news about the ML family of languages you find that Microsoft are taking F# commercial and will bundle it with Visual Studio. That is news worthy.

So I would say that [flamebait deleted by admin] ML is thriving in industry.

I've taken the unusual step of editing the parent comment, because flamewars about languages are not on topic here (see the site policies). The rest of the comment could be considered informative, so I did not simply delete the comment and have not (yet) put the user on probation, although that's clearly becoming a strong possibility.

If anyone has a problem with this, please email me privately (anton@appsolutions.com), or if necessary, start a separate forum thread.

### Hmm

I'm not sure that his post should be considered informative. I'd say the post is 'misleading' or mostly 'wrong'.

A few examples:

Genworks is not a biotech company. They are selling a system for 'knowledge-based engineering'. That's also clear to understand if you read the article or look at the Genworks website.

Lisp is mentioned in the Aaron article. Lisp is also mentioned on the website: http://www.kurzweilcyberart.com/aaron/history.html

The 'Lord of the Rings' article mentions Mirai (a Lisp-written animation suite by Izware).

ITA Software has talked about their use of Lisp in their product called QPX: http://www.paulgraham.com/carl.html (2001) and here http://www.itasoftware.com/pdf/SIAM2007.pdf , for example the core of their search engine is written in 200KLOCs of Lisp. Also web page generation software. It is also known who uses it. Orbitz is a user (http://www.orbitz.com/App/Partners?z=89d3&r=2s).

Sigh...

### Agreed

I'm not sure that his post should be considered informative. I'd say the post is 'misleading' or mostly 'wrong'.

I said "could be", not "should be". Either way, much as I'd love to see comments deleted for not living up to standards of accuracy or technical validity, the comment as published is within acceptable limits here.

### Lisp in industry

Where exactly does that AARON page (not the one hosted by Franz) mention Lisp, even in the "history" section?

The Lord of the Rings article quotes "Raitt" who once worked on a product written in Lisp called Mirai but now works for Weta. Raitt said "Though Mirai has a little better tool set for sculpting, the animators can interact with, and manipulate, the puppets in Maya".

I still cannot see a clear indication of what ITA or Orbitz are using Lisp for. Giving a ternary reference to Paul Graham quoting an e-mail from someone at ITA that mentioned Lisp six years ago is not exactly compelling evidence of Lisp's current use in industry. Especially when the author writes to Paul Graham with the objection "please make a note that this message is old". Your QPX link also fails to mention Lisp.

Like I said, Lisp is not gaining the same traction as other (modern) functional programming languages like OCaml, F#, Haskell and Erlang...

### OT: [Opine]

As I was reminded sometime back, programming languages never really die, so I'd say that calling in the coroner would be premature.

I've personally never understood any particular reason why there should be animosity between the ML and Lisp communities? Neither of these communities is large enough at the current time to give Java or C# a run for the money - even if they were to consolidate by moving into a single camp. And I don't see it as a zero sum game - both will benefit from the promotion of more language diversity, rather than less.

Final Note: Advocacy, especially of the negative variety, is to be discouraged, going against both the spirit and policies of LtU.

Language advocacy is off topic. This concern was repeatedly raised (in the forum) by editors about the "Lisp is dead" messages, to no avail.

Let me add that these messages suffer from two more substantial issues: They are not interesting, since the opinion was posted here again and again recently, and furthermore satating this again and again with no interesting or in depth discussion of technical or other relevant factors (or at least providing links to such discussion) has little value for LtU readers.

Any more messages along these lines will lead to messages from the user being put on the moderation queue and thus require approval prior to appearing on the site.

They are not interesting, since the opinion...

What opinions are you referring to?

no interesting or in depth discussion of technical or other relevant factors (or at least providing links to such discussion)

I cited dozens of examples, gave many links and several quotes. Marco even responded "I found the post informative.". I concluded that we have seen dozens of examples of modern functional programming languages gaining traction in industry but nothing credible to indicate that Lisp is gaining traction.

From your objection, I assume you would like to hear speculation on what language features resulted in this?

For example, that Wadler's views are implemented in F# as "active patterns" and are of great practical benefit in F# because they allow views of native .NET data structures to be created and pattern matched over without having to copy data structures into native F# types. Would that be more on-topic?

Perhaps a new LtU article comparing and contrasting OCaml and F# in detail would be on-topic and of interest?

I'll gladly contribute if you have any constructive criticism...

### Constructive criticism

Perhaps a new LtU article comparing and contrasting OCaml and F# in detail would be on-topic and of interest?

That would be of interest.

I'll gladly contribute if you have any constructive criticism...

My constructive criticism would be to stick to discussing the technical merits of F#, O'Caml, Scala, etc... And steer away from discussing Lisp. It is the juxtaposition that is the main source of consternation.

### Constructive criticism

Perhaps a new LtU article comparing and contrasting OCaml and F# in detail would be on-topic and of interest?
That would be of interest.

I'll write a blog article about it and cite it in an article here then.

### Sounds good

I have high hopes for F# and see it as a real chance to make some inroads on some large C# based projects that I work on. In reading Robert Pickerings book and doing some translations, I get the feel that there's some slant towards cleaning up some of the syntax (I'm thinking of his default use of the #light syntax directive). At the low level, the languages are quite similar. But programming in the large is significantly different - no modules in F# and it leans towards integrating with the .Net. I haven't quite figured out whether I like the syntax used to encapsulate .Net just yet. It gets a little more complicated - but that's probably to be expected in a FP language that is so tightly integrated with the OO world.

### OCaml vs F#

...no modules in F#...

Actually F# does have modules. It does not have functors.

The two languages are sufficiently similar that porting significant commercial code bases has been quite painless for us (~15kLOC per week per person). F# goes to quite some lengths to mimic the OCaml stdlib even when .NET already provides the same functionality in a different form (look at Dictionary and Hashtbl, for example, which are completely independent implementations of hash tables).

Anyway, I'll get into it all in detail in my blog... :-)

you know Marco was referring to my post being informative about you.
http://lambda-the-ultimate.org/node/2491#comment-37511

BTW, here's an excerpt from Aaron's page, the one which you said had no Lisp references:
http://www.kurzweilcyberart.com/aaron/history.html
"AARON was built using Franz Inc.'s Allegro CL development tools."

along with Franz logo and link...

### Let us cool off

I think the admin is being a tad churlish. A discussion of FPL wins in the real world will necessarily devolve into a discussion of wins of this vs. that language because users are not interested in FPLs in general but in the specific language they are using: they live in separate communities, they are not oecumenic in that way. The abstract category of FPL that you are using exists in academia and in some technical forums like this one, not so much in the real world. Thus if you want to discuss real-world use of languages, that is something you have to face: it doesn't make sense to lump together, say, Lisp wins and ML wins and it is appropriate, on the contrary, to discuss whether Lisp or ML or both or neither is getting traction.

### Explanation

In another context, the parent comment might make sense. However, in this case the issue of Lisp vs. ML was originally raised and subsequently pushed not by a regular LtU member who has demonstrated an interest in the subjects discussed on LtU, but instead by someone who has admitted in this thread that he sees stirring up controversy as a way to advertise his business. He achieves this by making unnecessarily provocative statements, i.e. deliberate flamebait or trolls.

We don't see any value in allowing that to continue here. A number of regular members have made it clear in this thread, and in private email to the admins, that they agree. Anyone who is looking for that sort of discussion can find plenty of it on comp.lang.lisp and comp.lang.functional.

Anyone who is looking for that sort of discussion can find plenty of it on comp.lang.lisp and comp.lang.functional.

No, don't. Neither of those newsgroups is for FUD.

### Observation

I was observing that such discussions have regularly occured in those places, as I'm sure you're aware. I wasn't endorsing newsgroup abuse. However, I should have stuck to dealing with what is acceptable here, and not dragged other forums into it.

### My comment was intended for everyone

My comment was intended for everyone (IOW, if you want to promote your stuff, keep it on your own site), but I didn't make this clear. Nevertheless, I agree with what you say.

### ML vs Lisp

As I was reminded sometime back, programming languages never really die, so I'd say that calling in the coroner would be premature.

"Lisp is dead" meant that "Lisp is not gaining the same traction as other (modern) functional programming languages like OCaml, F#, Haskell and Erlang".

I've personally never understood any particular reason why there should be animosity between the ML and Lisp communities?

The success of any modern functional programming language breeds contempt among the Lisp community. Consequently, interested programmers asking for objective comparisons between Lisp and OCaml are met with extreme hostility by the Lisp community. Note that the converse does not happen.

Neither of these communities is large enough at the current time to give Java or C# a run for the money - even if they were to consolidate by moving into a single camp. And I don't see it as a zero sum game - both will benefit from the promotion of more language diversity, rather than less.

The ML community would not benefit from the promotion of Lisp, or vice-versa. For example, the recent productization of F# by Microsoft has had a strong positive effect on OCaml, with thousands more people now learning about OCaml.

Even if anyone did announce a significant investment in Lisp, I believe the ML community would gain nothing from it.

Final Note: Advocacy, especially of the negative variety, is to be discouraged, going against both the spirit and policies of LtU.

I assume that I may draw comparisons between the relative success of different families of functional programming languages in industry on a thread about large-scale successes of functional programming, and question the validity of statements made by others?

### Setting the agenda

I assume that I may draw comparisons between the relative success of different families of functional programming languages in industry on a thread about large-scale successes of functional programming, and question the validity of statements made by others?

From the LtU FAQ:

"Keep in mind that LtU is a community site and regular and respected members are expected to let posters know when their posts violate the spirit of LtU. If you receive responses of this sort, it is firmly suggested that you review your contribution, and accept that your style of discussion or choice of topic may be inappropriate for this site."

To put it somewhat bluntly... You seem to be following an agenda that purposely pits one family of programming languages against another. That sort of advocacy is not particularly welcome.

The question of Common Lisp is mostly off-topic to the main thread anyhow. Common Lisp is not generally considered to be a functional PL, so its fate is not really tied to the original question. Scheme would generally be classified as functional, but that doesn't seem to be the under discussion.

Finally, as Ehud noted earlier, this dicussion is not particularly productive to advancing our state of knowledge concerning programming languages.

The success of any modern functional programming language breeds contempt among the Lisp community.

If one goes about constantly posting how ML is waxing and Lisp is waning, it's little wonder that the response can be lukewarm. Personally I prefer to hear tales from people that are extemely fluent in Lisp and O'Caml - aka Oleg.

To put it more bluntly: by reading the type of items posted to the home page and the types of discussions that usually take place on LTU, not to mention prior complaints in this thread and Chris's suggestions, it should be clear why this type of discussion, both in tone and in subject, is unwelcome, especially if prolonged.

LtU is indeed a community site. Part of the respect I expect from members of the community towards each other is to listen to the sort of rebukes I and others have posted about the posts that required intervention. The firmly suggested wording in the policy page is not poetic license. If someone else, other than the member who received the complaint, wants to argue in favor of this type of discussion, I am all ears. Otherwise, the next step is putting the user on probation, so that all future posts will have to be approved prior to appearing on the site.

### Common Lisp

You seem to be following an agenda that purposely pits one family of programming languages against another.

Of course: I'm trying to draw an objective comparison and you can't do that without pitting languages against each other. From my point of view, the references to uses of Lisp in industry are not credible, not significant and not recent. In contrast, the references about SML, OCaml, F#, Haskell and Erlang in industry are credible, significant and recent.

In my mind, advocacy would be someone here telling others to use one language rather than another but not someone noting which languages are most popular in industry.

Common Lisp is not generally considered to be a functional PL...

I'm surprised to hear you say that, particularly when others in this thread are discussing whether or not delegates in C# make it an FPL.

IMHO, Lisp and JavaScript are close enough to being FPLs (for pretty much any definition) that they are certainly worth mentioning here whereas Python and C# or Java are not. That is entirely subjective, of course.

Do you agree that the meaning of the phrase "functional language" is used more often to mean "has first-class lexical closures" rather than "side-effect free" these days?

### Scheme vs. Common Lisp

In my mind, advocacy would be someone here telling others to use one language rather than another but not someone noting which languages are most popular in industry.

Given vested interests in the outcome, I see it as advocacy similar to that which is taking place in other venues. Personally I enjoy reading your writings on F# and O'Caml. At the same time, I cringe anytime you mention Lisp. (Hence my advice above).

I'm surprised to hear you say that, particularly when others in this thread are discussing whether or not delegates in C# make it an FPL.

Neither C# nor Common Lisp should be classified as functional programming languages. Both may support limited forms of functional language constructs or programming in a functional style, but neither is an FPL.

[Edit Note: Must learn to curb on excesses....]

IMHO, Lisp and JavaScript are close enough to being FPLs (for pretty much any definition) that they are certainly worth mentioning here whereas Python and C# or Java are not. That is entirely subjective, of course.

JavaScript, Python, C#, and Java rely too much on mutation to be considered an FPL - they belong to the imperative class of object oriented languages. Even though both Scheme and Common Lisp are in the Lisp family of languages, Scheme would be considered an FPL and Common Lisp would not. My personal opinion is that there is a healthy respect between the ML and Scheme communities. OTOH, Common Lisp is as different from Scheme as it is from ML.

Do you agree that the meaning of the phrase "functional language" is used more often to mean "has first-class lexical closures" rather than "side-effect free" these days?

In over-simplified terms, I identify FP with: (1) referential transparency; (2) first class and higher order functions - HOFs; and (3) parametric polymorphism and pattern matching. Eschewing mutation (at least as the default) is needed for 1. Closures are needed for 2. The third one is on a bit shakier ground since some languages we consider to be FP do not sport them. Parametric polymorphism is usually associated with static typing. Languages like Erlang use duck-typing to get a somewhat similar effect.

### Vested interests

Given vested interests in the outcome...

People come to us for advise on functional programming in industry precisely because we are impartial. Implying that we have a vested interest in showing some languages to be more popular in industry than others is silly.

Language preference in advocacy is typically driven by religious faith rather than anything objective. As my posts here have already shown, we've done our research, presented objective evidence and drawn our conclusions. That is not advocacy.

I see it as advocacy similar to that which is taking place in other venues.

Then you are mistaking advertising on usenet for advocacy here. On usenet, controversy fuels huge threads of discussion about us and our products, which is very cost-effective advertising for us. Here, the value for us is in reaching a wider audience, so we can afford to present useful information with self-citations rather than stirring up controversy.

JavaScript, Python, C#, and Java rely too much on mutation to be considered an FPL - they belong to the imperative class of object oriented languages. Even though both Scheme and Common Lisp are in the Lisp family of languages, Scheme would be considered an FPL and Common Lisp would not. My personal opinion is that there is a healthy respect between the ML and Scheme communities. OTOH, Common Lisp is as different from Scheme as it is from ML.

I identify FP with: (1) referential transparency; (2) first class and higher order functions - HOFs; and (3) parametric polymorphism and pattern matching.

In your previous statement you imply that purity is an essential part of a functional language. I appreciate that many people (particularly from the Haskell community) agree with you but I find drawing the functional line between Lisp and Scheme far too subjective. Indeed, the distinction is so blurry that I would avoid using the term "functional programming" in many cases.

Incidentally, have you studied LINQ and C# 3.0? You might be enlightened by articles like this one.

### Implying that we have a

Implying that we have a vested interest in showing some languages to be more popular in industry than others is silly.

No, what's silly is claiming you don't have a vested interest, as you continuously promote your consulting business and chosen languages on different forums.

As my posts here have already shown

Your first post on here was a blatant advertisement for your consulting business embedded in a cheerleading post for F#. That post was removed for obvious reasons. Now you have managed to post your consulting link in a dubious thread that belongs more on comp.lang.functional than LtU. Congratulations, you have successfully played the search engine optimization game. Isn't that enough, or do you need your X vs Y language debates here too?

### Selling...

Here, the value for us is in reaching a wider audience, so we can afford to present useful information with self-citations rather than stirring up controversy.

But where is the value for LtU?

### Popularity is seldom of interest to the topic of this site

This website is primarily focused on programming language theory, not programming languages per se. That may seem like a ridiculous distinction at first, as the former is informed by the latter. But many surface details of specific programming languages are largely irrelevant here.

Comparisons for programming languages, especially those involving value judgements such as "better" or "more suitable for", require caution. For one thing, such comparisons, especially when not constrained (i.e. better at doing X for purpose Y), tend to escalate to flamewars; the participants of this forum seek to avoid endless arguments about whose language, paradigm, or typing discipline is "the best". For another, rigorous analysis of such questions is frequently a matter of software engineering as opposed to theoretical CS--and few such analyses are ever done and published. Many issues which frame the debate are matters of taste and beyond the reasonable purview of science.

Third, the introduction of popularity or "design wins" into an argument--is seldom productive to the topic of this forum, and often is little more than a glorified pissing contest. Languages like C/C++, Java, Javascript, Perl, and VB are far more "popular" than any functional language these days, regardless of strictness, purity, or typing discipline--yet nobody would suggest that we should all abandon PL research and just code in the current industrial fashion. Likewise, there may be an interesting line of inquiry as to why F# is being adopted much more and CL is not--but suggesting that this proves that F# is "better" than CL (or the opposite) is sheer fallacy. FWIW, I'm neutral on any F# versus Lisp debates, such as they exist. Simply noting which languages are most popular, however, is a "don't care" for most participants of this forum; we're mainly interested in the next generation of PLs and how we can improve. Arguing about which language is most popular, and disputing reported uses of a language in furtherance of such a debate, is definitely off-topic.

To address your last point--in my view, first class lexical closures (or a close approximation thereof) are a necessary but not a sufficient condition for FPL. Some means of doing higher-order functions is a requirement. Absolute purity is not a requirement, but a FPL should IMHO discourage use of mutable variables, and provide features which make them unnecessary in many cases--cheap recursion and TCO, libraries which avoid side effects, etc.

### Hmm 2

Aaron: right on the page, fat on the bottom: "AARON was built using Franz Inc.'s Allegro CL development tools." Allegro Common Lisp. Wikipedia ;-) on Aaron: 'Development of AARON began in the C programming language then switched to Lisp in the early 1990s.'

The Lord of the Rings article: " Raitt decided the best way to define the characters would be to sculpt combination shapes for their expressions. Mirai, a 3D sculpting engine that has been around for about 17 years, was the tool of choice.". Mirai was used for sculpting and modelling. All described in the article.

ITA. ITA Software is a company that developed a system called QPX. QPX is partly written in Common Lisp. The core search engine is mostly written in Lisp. Orbitz is one of their customer who uses that system. You can see from the website that they have lots of other users like Air Canada, Continental and others. QPX is an existing product. Currently they work on a new airline reservation system (RES), also partly in Lisp. That's a huge challenge. They have also multiple positions open for people with knowledge of Lisp. They also use Python, Java and C++. Technologies we like: Lisp. That 'someone' who wrote the mail is one of the Co-Founders and their Chief Scientist. There can be more said, but I'm getting tired...

For the last line the typical response is: â€œLisp doesn't look any deader than usual to me.â€ ;-)

### Lisp in industry

If there are still any genuine industrial adopters of Lisp then I would certainly like to investigate them and refer to them. However, I need credible sources and citations to Wikipedia, an out-of-date quote by Paul Graham and an anonymous statement on the ITA website just don't cut it.

I can well believe that Air Canada and Continental are customers of the company ITA that made a product called QPX that was once written in Lisp, and ITA are still advertising QPX. However, even if that is true it is not a primary relation between those major air lines and Lisp.

I'll it on my list but if you have any more reliable sources to back this up I'd really appreciate it.

### See their job openings

http://www.itasoftware.com/careers/jlisting.html?jid=8

about eight are lisp related. And they recruited quite a few lispers the last couple of months.

Furthermore I know from ITA insiders they are expanding their lisp activities (and market) as should be a logical conclusion, seeing their hiring strategy.

More to the point: is there a particular reason ITA should be lying about their lisp usage? Is there something inherent about Common Lisp that makes it by default unfit for the airline industry?

More to the point: please confine your anti-lisp crusade to cll mr Harrop. Or better of course, stop it altogether if you can find the power within you.

### ??

LISP is still in use @ ITA - I was just recently reminded by it from a friend who joined the company this year. You don't just ditch the #1 code base in your field on a whim.

### Lisp in industry

Any idea how much Lisp code is still in use at ITA or how much revenue they earn from it?

### Common Lisp at ITA

Re: #comment-37906:

Any idea how much Lisp code is still in use at ITA or how much revenue they earn from it?

It's a privately held company. No one's going to disclose the kinds of information you're asking for :)

As far as the past and current use of Lisp, Dan Weinreb has this to say on the subject:

We almost certainly have the largest team of Common Lisp programmers in the world.

### Common Lisp at ITA

Aww, sure, I'll disclose it, what the heck. The answer to how much revenue we get from the Lisp software is: all of it. Hey, it pays my salary...

Certainly Common Lisp is still in use at ITA, as much as it ever was and much more. QPX's basic technology has not changed in years, so what you've seen written about it is still true. We have more customers these days; many airlines use QPX. See our web site for a list of customers who have given us permission to talk about them. QPX has been substantially extended over the years and given new capabilities. It's under active development all the time and it is operated 24/7 at multiple data centers.

I am working on the other large project at ITA, a new airline reservation system, initially for Air Canada, to be known as Polaris. It has many components and ties into QPX and our other technologies for knowing how many seats are available on what flights and so on. It is a three-tier architecture (four if you count the web browser). The presentation tier is in conventional Java (servlets, etc). The business layer ("core") is in Common Lisp. The database is conventional Oracle. There are other pieces written in Python, plus the odd Perl and shell script and such.

The Common Lisp part is big. Lots of lines of code; I'm probably not supposed to say exactly. We have a huge team working on it. Whereas QPX is largely compute-bound, Polaris is a transaction-processing system (see "Transaction Processing" by Gray and Reuter). The "core" is by far the most complex and interesting part of Polaris.

My own work has to do with making the system highly-available, and particularly with being able to upgrade to new software versions while the system is running. The system has to be up all the time, once it goes into production (many months from now). Mostly this particular issue doesn't have much to do with Lisp one way or the other.

Regarding the learning curve: not really a problem. We give everybody copies of "Practical Common Lisp" and they learn it quickly. This is partly because we only hire excellent programmers. I like working at ITA so much because the people I work with are so great. I learn new things every day.

Ah, but is it "functional"? I see there is another discussion group named "What are the properties of functional languages?" If there were an agreed-upon crisp definition of what the question means, I could try to answer it. Common Lisp is a multi-paradigm language, supporting procedural, functional, object-oriented, etc. programming. Do we use higher-order functions? Sure. Do we use object-oriented programming? Yes, very heavily; lots of CLOS, a home-grown object-relational data mapping system based on CLOS, etc. Does our code look like the Scheme code in "Structure and Interpretation of Programming Languages?" No. We get lots of mileage our of Lisp macros; as I understand it, so does QPX.

### PolySpace at MathWorks

MathWorks (you know, the makers of MATLAB) recently bought PolySpace (April 2007).
PolySpace specializes in source code verification technology, and it's all SML + MLton (AFAIK). They're a big MLton user, it seems.

That's pretty industrial - and successful - to me. Even more so when you consider who PolySpace's clients are: big, big names in Aerospace, Automotive, Biotech, etc.

here and
here too.

Also, I believe PolySpace employs Abstract Interpretation (Google: Cousot) throughout its source verification product.

It's just the ideal showcase for the power SML can bring to software engineering. I don't know if they use PolySpace on Matlab itself - that would make me feel better, as I use it myself - Consider the C bugs in Mathematica, or the recent multiplication bug in Excel.

### Standard ML still in industry

This is fascinating, thank you. I was under the impression that Standard ML was basically dead in industry.

### You forgot something

Mr. Harrop, you forgot to mention that Matlab uses (your?) OCaml code on their FFT routine (that subsequently generates C code). Shall we count that?

Also, let's not forget that the new ECMAScipt ("Javascript") specification is being written in SML.

### FFTW

The FFTW library is certainly an excellent example of commercial OCaml code, being widely used as a core component of MathWork's MATLAB.

I did not write FFTW. I suspect you were thinking of my work for Wolfram Research, where I wrote a prototype Mathematica JIT compiler in OCaml that could evaluate Mathematica code up to 600x faster than Mathematica itself! That was another example of functional programming in industry that I forgot... :-)

### hmm

Mr. Jon D Harrop, I presume 30 means your age?

tired of spamming the comp.lang.lisp newsgroups?

Found lambda-the-ultimate to be a more effective media in your anti-Lisp crusade?

ML languages certainly offer many good features, but so do Lisp languages. Saying one is better or more modern or more useful than the other is no more productive than the old dynamic-vs-static-typing debate.

I think your energy at the subject is now explained by your age...

"Finally, don't forget that JavaScript is a functional programming language!"

tell that to most javascript webmonkeys! They certainly don't know anything other than imperative style at its worse...

### Keep it technical

I sympathize with the spirit behind this message - I erased some similar comments from my own earlier reply before posting - but let's stick to the technical discussion here.

If a poster gets particularly obnoxious, he'll be put on "probation" and his comments moderated. But as usual, ignoring obvious trolls is often the most effective strategy.

### Keep it technical, please ;-)

I found the post informative.

### I don't think so

I think people underestimate the professional JS community [this is as person who came up out of it and the flash community]. The linguistic barbarities of programming in the web community was astounding 10-15 years ago - languages and frameworks gave about as many of the necessary abstractions as ASM. For example of the community's sensitivity, alistapart.com provides some amusing reading - an incredible amount of care is put into structuring and styling static content cleanly (albeit with the subtext of the content being generated). The push for (often functionally inspired) frameworks to ease security, modularity, efficiency, compatibility, and expressive concerns is no surprise. To start in this world, you need a pixel-perfect mindset, and that ultimately reflects in code as skill level increases.

If the comment is that the technology is accessible for hobbyists... sure. GUI-rich programming is fun and HOFs streamline callbacks (not that I'm a supporter of the latter use).

### More industrial use of ML

Here at LexiFi we've made extensive use of the Caml language for the modeling of divertive financial products (swaps, options etc). Our solution includes software for modeling the life cycle of a product, as well as pricing them. It is closely related to the solution described in the paper by Jean-Marc Eber and Simon Peyton-Jones that Jon mentions.

### C#

The term 'functional programming' seems to be attached firmly to names like ML and Haskell. But don't forget that many (if not most) of the features of ML (higher-order functions, closures, garbage collection, tail call optimization) have been retrofitted into technologies such as C# and LINQ and the CLR and these are more widely used than the rest of the pack put together.

The traditional set of functional languages differ on many axes (eager/lazy, pure/imperative, statically typed/dynamically typed, type inference on not) .. I'd say that C# occupies a cell in that matrix.

### Yes, but

That doesn't mean, though, that most people using C# are doing functional programming, any more than people using C++ are necessarily doing object-oriented programming.

### Functional programming in C#?

My instinct was also to quip that C# is not a real functional programming language. However, just the threading model of Windows Forms will encourage many C# programmers to use delegates, for example.

Whether or not you consider that to be "functional programming" is another matter, of course.

### The six-horse Concord Coach cannot be beaten!

The Haskell in industry page might be of interest.

However, this game of examples of major real-world systems is a little like the jobs ads for people with 5 years of experience in a technology which debuted 2 years ago. It's a game where the deck is heavily stacked in favor of the ad-hoc languages, simply because those languages have a historical advantage and an advantage in number of users, which gives them a strong ecosystem advantage (a.k.a. network effects). Even if the languages themselves are at least as good at supporting team development, their supporting infrastructure is typically not at the same level.

The seriousness of this situation clearly calls for a car analogy. As long as no-one has replaced the Wells Fargo stagecoach fleet (once the largest in the world) with a fleet of automobiles, automobiles can be made to seem like an unproven choice. And there's some merit to that: the average rider might well be better off sticking to his horse and carriage until there are gas stations and mechanics on every corner. But for those who want to outperform the average rider, there's a powerful alternative that actually is proven, it's just that the cases doing the proving don't look like what the average rider is used to.

So if you're a project manager who could get fired for making the wrong technology choices, and your software development strategy isn't critical to the company's success — i.e. you can afford not to be on the leading edge — then playing it safe with the languages everyone else is using can make sense. You won't get fired because of it — there's safety in numbers even if you fail. You don't really need to speculate about technical reasons why unfamiliar languages won't work for you, or come up with questions that will confirm your prejudices.

But if you're a programmer who plans to be in the field for much longer, not learning to use these languages is a ticket to obscurity, because even if the languages themselves don't take over anytime soon, many of the ideas they carry will. That's already started to a small extent, but it's only the beginning. There's a lot of gratuitous bug-inducing mutation still to be stamped out, and the programmers who have no idea how to do that are going to find themselves at a disadvantage.

The Galois people are using Haskell. (As a sidenote, they also steal our #haskell IRC channel friends.)

### A commercial Linux distribution uses Haskell

Linspire is a Linux distribution (as I understand it, it's the easiest one for the hypothetical "common user") that uses Haskell:

If that is still true it's a big success story, too.

### Still true?

I gather Clifford Beshers has left Linspire. I guess that might leave a hole in their Haskell development team.

### Update?

Does anyone have an update on this? I can't find any recent references to Linspire at all, let alone their continued use of Haskell since their lead Haskell developer left...

David Fox and I have left Linspire, Jeremy Shaw is still there finishing up some of the Haskell tools. We've formed a new company, SeeReason Partners, which you can read about in the HC&A Report.

We plan to continue developing the autobuilder, a Haskell program which builds Debian packages and archives. Our goal is to provide current archives of all Haskell tools and packages at hackage, so they will be easy to install on Debian based systems.

### Erlang

Have you ever used a cell phone? If you have chances are pretty big you call was routed using a bit of Erlang code. Ericsson developed Erlang in house and has used it extensively to program their telecom platforms. I don't have any concrete figures but the numbers for Ericsson should pass your requirements with ease :)

Credit Suisse has also joined the functional bandwagon. They're using Haskell.

### I hope these won't become

I hope these won't become the only only showcases in a decade. At least Ericssons engagement is not really new.

I think it's naive to expect the social acceptance problem of certain technologies ( and FP in particular ) will be solved by the industry and there will be a big player advocate Haskell instead of Java or .NET. Instead communities need to provide portals simplifying recruitment.

We are just at the beginning of a culture that is strongly influenced by the way the web can work effectively.

### Companies using Lisp

I've put together a page on my website with a list of companies I've found that are using Lisp. It's not finished but there are about 40 companies from North America, Europe, and India so far.

Lisp Companies

### One more example

Guild Software, creator of the Vendetta Online multiplayer science fiction game, used Lisp for their main server. There were performance and maintenance concerns, I believe, and they've been working on a replacement system written in Erlang. The game's news page has some discussion of the new system, including this tidbit from early December:

We're still working towards our 1.8 milestone, which will hopefully include three different Hives and a fully distributed Kourier back-end. Erlang (the language used to develop Kourier) is built to be distributed, but so far we haven't done so. Now that the system is beginning to go "prime-time", we're going to balance it across the entire cluster, to make sure we have a stable and scalable base on which to build future gameplay features. ...