Live data from Hacker News

How Lisp is Going to Save the World

landoflisp.com

161–170 of 239 posts

Re: How Lisp is Going to Save the World

#161

Earlier quoted context omitted.

Seriously, this is a great point. One of the big problems with a small community of programmers who all think of themselves as elite, is that tasks like documentation and tutorial writing go by the wayside. This comment should be a wake-up call to any smart and far-sighted individuals who want to promote a language.

Yep. They have time to draw elaborate cartoons, but not elaborate documentation! Funny how that works.

Actually, that cartoon is part of an elaborate book (landoflisp.com) meant to school beginners on Lisp.

Re: How Lisp is Going to Save the World

#162

Earlier quoted context omitted.

Seriously, this is a great point. One of the big problems with a small community of programmers who all think of themselves as elite, is that tasks like documentation and tutorial writing go by the wayside. This comment should be a wake-up call to any smart and far-sighted individuals who want to promote a language.

Is there a open source Common Lisp library that you'd like to see better documented? Also, if you're (or anyone else is) interested in working on a Common Lisp environment tutorial, shoot me an email. I've been working on one but haven't launched it yet.

> Is there a open source Common Lisp library that you'd like to see better documented?

I was talking as a long time member of a different programming community with similar attributes. (Smalltalk - since 1998)

Re: How Lisp is Going to Save the World

#163
post #150

Earlier quoted context omitted.

"Compared to Haskell I found the syntax very obtuse and it was not obvious why Lisp would be more powerful than Haskell." Language "power" is ill-defined, and basically means "good". If you think that homoiconicity is good, then you probably like lisp. If you think that referential transparency is good, then you probably like haskell. Those are mutually exclusive, so one language can't really have both. But either on…

How is it that referential transparency (the ability to swap a reference with it's value: no hidden inputs) and homoiconicity (both the source and the resulting syntax tree sharing the same structure) are mutually exclusive? What homoiconicity offers is the macro system, the ability to operate on the syntax tree as a regular language data structure. The difference is a language like Haskell enforces referential trans…

"How is it that referential transparency..."

That was incorrect, I meant: "the kinds of metaprogramming associated with homoiconicity are mutually exclusive with referential transparency".

A macro could not, for instance, take a variable name as an argument and return a result that's based on the value of that variable and maintain referential transparency. So that would be a pretty weak macro system.

I suppose there may be other uses for homoiconicity, but I don't know enough about lisp to comment on that.

Re: How Lisp is Going to Save the World

#164
post #150

Earlier quoted context omitted.

"Compared to Haskell I found the syntax very obtuse and it was not obvious why Lisp would be more powerful than Haskell." Language "power" is ill-defined, and basically means "good". If you think that homoiconicity is good, then you probably like lisp. If you think that referential transparency is good, then you probably like haskell. Those are mutually exclusive, so one language can't really have both. But either on…

How is it that referential transparency (the ability to swap a reference with it's value: no hidden inputs) and homoiconicity (both the source and the resulting syntax tree sharing the same structure) are mutually exclusive? What homoiconicity offers is the macro system, the ability to operate on the syntax tree as a regular language data structure. The difference is a language like Haskell enforces referential trans…

"lisp it is up to the developer whether or not a function will be referentially transparent"

Although that may compromise the ability of the compiler to detect mistakes even when the developer writes all referentially-transparent functions. Not sure about that, but I suspect that it does in practice (currently) even if not theoretically inherent.

Re: How Lisp is Going to Save the World

#165
post #108

Earlier quoted context omitted.

> If it is so good why ain't it is used more? Speaking just for myself, it's because most commonly available distributions (such as SLIME) require you to learn a new editor on top of learning a new language. I think emacs is great, but it's not my editor of choice, and when a language distribution all but requires you to use emacs, it's going to have a hard time gaining traction with me. This may have changed over th…

There is slime for VI. And Paul Graham and team used VI and clisp to build the store software--no IDE. If you read Coders At Work http://codersatwork.com/ the grown-ups don't use IDEs.

Well, I work solely with VIM now, but I have worked with Visual C++ 6.0 in the past and later with Zend Studio 5 & 6 version and then with Komodo IDE. I never touched Java, but I briefly came back to Visual Studio when doing some projects in C# and then when learning F#. There's also DrRacket, formerly DrScheme, an IDE for Racket, which I use sometimes and love (I used it instead of Emacs for other Lisps too btw). Ok, to the point: you are wrong.

Take my VIM for example, which I use for Python and (Java|Coffee)Script development (along with Erlang and a few other languages for hobby projects). I have a file list/tree/browser with NERDTree. I have a list of classes and functions in currently opened files with TagBar. I have "go to definition" and "display help/docstring" through Rope, along with four different auto-completion modes (partially built in, enhanced with SuperTab and a few other plugins, including Rope). Similarly I have support for refactoring from it. I have "find in files (quickly)". I have "fuzzy file name matcher" with Command-T. I have three different linters for Python. I have access to git log, blame, status, add and everything else with fugitive and diff is pretty, side-by-side one thanks to vimdiff. I can open remote files easily (this is built in). I have a bar with snippets (with placeholders I can fill in when pasted, of course) with SnipMate. I can open command line (like bash, ipython or coffee) in a window or tab with Conque. I can easily evaluate bits of code thanks to IPython (and thanks to their recent refactor, it's really paying off!). I use zencoding when I have to write HTML structure. And these are just things I use most often.

Now, I use VIM, which, I assume, means to you that I don't use an IDE - but what is the difference between, say, Komodo IDE and my VIM (aside from my vim being able to display in the console) really? It's IDE all the way down to unix shell and all the way up to git integration... And I'm old enough to be called a "grown up". Of course, I assembled my IDE myself from pre-made and some custom components, but it's IDE nonetheless.

The thing is that IDEs are there for a reason. Every single feature I mentioned above is a timesaver to greater or lesser extent. Every one of them increases my productivity in some common situation - and we're talking about Python and back-end (mostly) web-development here, which has much less repetitive, tedious tasks than, say, writing MFC app in C++.

Anyway, if you want to program in Notepad - feel free. Just don't, really don't, try to convince anyone to do the same by saying that notepad is somehow superior to Visual Studio for programming. It isn't. You'll understand this when you have to immediately fix a bug in production code on the server with something like nano, joe or mcedit and you introduce three other errors in trying to do so due to unbalanced parens, messed up indentation and a huge number of other issues that IDEs (yes, VIM included) protect you against. Well, I guess you need to grow up first to get access to that production code, I mean afterwards ;)

Re: How Lisp is Going to Save the World

#166
Most of the time, you don't want to save the world because this presents scaling problems. Instead, save a little corner of the world and be open about how you are doing it. If you do this right, then you will garner lots of imitators. Then if your way of "saving the world" is well documented and robust enough to avoid the "cargo cult" pitfall, you will convince some large part of the world to save itself.

Note the implication: You don't save the world by telling it, "You're doing it wrong." You save the world by getting the world to covet your success.

Re: How Lisp is Going to Save the World

#167

Earlier quoted context omitted.

I'm sorry but what you're saying is immediately obvious. No one in the functional programming world is laboring under the impression that state doesn't exist. The real issue is whether you think it's worth separating out code that can be reasoned about in a mathematical fashion from stateful code that has to deal with mutating concerns. Functional programming is where research on improving abstractions to better allo…

What makes you think that stateful code can't be reasoned about in a mathematical fashion?

Well, there's certainly a popular conception among program analysis and formal methods researchers that side effects make analysis much more difficult.

Re: How Lisp is Going to Save the World

#168
post #108

Earlier quoted context omitted.

There is slime for VI. And Paul Graham and team used VI and clisp to build the store software--no IDE. If you read Coders At Work http://codersatwork.com/ the grown-ups don't use IDEs.

Ignoring the condescending remark for now, it probably was possible to run lisp without Emacs, but none of the tutorials mentioned how. They all pointed towards Emacs. If I recall correctly, one tutorial (and several IRC lispers) even stated the following: "How do I use this with vim? Just use Emacs + SLIME, you'll be better off for it." It's probably changed (at least I certainly hope it has), but it certainly hampe…

It didn't change last time I checked - Emacs is still almost mandatory for almost all tutorials on Lisps (I searched for beginner tutorial for Clojure about half a year ago). I find this attitude stupid too. Emacs is a great editor, not to mention operating system, but I just don't like it and I feel that I have the right to do so. It shouldn't be too costly to list the alternatives and help with getting expected functionality in other environments.

This was never really an issue for me though, because I was lucky enough to start my adventure with Lisps from Racket and it's excelent IDE, DrRacket. I then used it with other Lisps, because I was already familiar with it and adding some keywords (well, names - for indentation purposes) was trivial. I didn't use them (other Lisps) long enough to be seriously irritated by the lack of built-in repl, so obviously YMMV - but I would recommend DrRacket as low-entry-barrier alternative to Emacs for Lisps editor - it handles parentheses rather well :)

Re: How Lisp is Going to Save the World

#169
post #126

Earlier quoted context omitted.

> I found the syntax very obtuse and it was not obvious why Lisp would be more powerful than Haskell. The easiest answer to that is, there's no syntax, which makes reimplementing your own Lisp parser trivial (one single function call, in fact). This in turn makes reimplementing your own Lisp, inline in Lisp, similarly trivial. That sounds like something out of an SICP exercise - and it is - but the same properties ma…

Have you got a good example where Lisp macros would work but standard Haskell would "fail"? I've done some compiler work in Haskell like writing programs (semantic actions) as algebraic data structures and then transforming or interpreting the tree. Would I gain something by using Lisp macros in this instance?

Have you got a good example where Lisp macros would work but standard Haskell would "fail"?

http://people.csail.mit.edu/gregs/ll1-discuss-archive-html/m...

Re: How Lisp is Going to Save the World

#170

who write this crap? i wrote in lisp (scheme), this is the most bugged language i ever used. and i used more then 5. this is non debugable language, it it makes it bug full. you have to follow complex ideas, and keep scores of ideas, this is not for normal humans. when you pass the wrong type and not support it, it goes to hell, and as a programmer you start to flame. list, is a piece of shit for the masses, its usef…

Oh, only five other languages? Come back after your twentieth and we'll talk...

Now seriously - in which Scheme did you "write"? Racket has excellent debugger and brilliant contract system and exceptions, not to mention a repl and powerful type system. I'm sure you didn't want to display your lack of experience and knowledge, it just happened; I won't hold it against you, just don't write anything more about the thing you know nothing about.

Post reply on HN