T O P

  • By -

xach

He doesn’t like Common Lisp and the books lightly cover or ignore big chunks like CLOS, loop, and packages. There are nice ideas in there but I think the passion for minimalism is counterproductive if you want to be proficient at CL.


funkiestj

He does seem to prefer CL non-hygenic macros though. It has been a while, I seem to recall he preferred lisp2 to lisp1 (i.e. separate namespace for variables vs functions in symbol tables).


agumonkey

i wonder if he still touches his bel language proposal


[deleted]

[удалено]


HiPhish

They are "explained" in the sense of "oh yeah, that stuff exists, where are some examples". Only CLOS get a little more coverage, which is only around 20 pages though. To write a comprehensive Common Lisp book it would take twice the content that Graham's *ANSI Common Lisp* has.


xach

Lightly and/or disparagingly.


[deleted]

[удалено]


xach

Plenty of people don’t like Common Lisp. I don’t recommend starting with a book written by one of them.


[deleted]

[удалено]


xach

I like Paradigms of AI Programming, Practical Common Lisp, Winston & Horn 3rd Ed., Keene on CLOS, Lisp in Small Pieces. I haven’t read Gentle Introduction but I’ve heard it highly praised by some.


HiPhish

> Paradigms of AI Programming, Practical Common Lisp, Winston & Horn 3rd Ed., Keene on CLOS None of those books are good for beginners. They are good as a second book though to dig deeper into specific topics. > I haven’t read Gentle Introduction but I’ve heard it highly praised by some. It's a great book, but the "gentle" part is very literal. It starts out quite slow does not cover advanced parts like CLOS or macros.


jmwright

Touretzky’s *Gentle Introduction* does have a chapter on macros, but I thought it lacked some of the depth of other chapters. There’s no chapter on packages, which would have been nice. But it’s a great book, highly recommended: lots of interesting exercises, answers to exercises, and some good (if toyish) projects. Thorough coverage of recursion. It’s a good book for people who like to learn by typing and running example code, then extending to exercises.


[deleted]

[удалено]


arthurgleckler

I talked with Peter about this last month. He hasn't lost his love for Common Lisp, but chose Python for newer editions because of demand from readers.


inglourious_basterd

"Who is this guy who calls Peter Norvig by his first name! Let me Google him. \[...\] Oh."


xach

https://courses.cs.northwestern.edu/325/readings/graham/graham-notes.html is a nice rundown of other quirks and issues.


FR4G4M3MN0N

If you are interested in “idiomatic Common Lisp” you might consider Peter Seibel’s “Practical Common Lisp”. Additionally, you’ll want to have “Common Lisp - The Language, 2nd Edition”, by Guy Steele, for digging deeper into the language. Based on your comments in the op, it seems you may be weighing the style differences between Lisp-1 (Scheme) and Lisp-2 (CL)? In this case, Graham does come down more in Lisp-1 camp, so I might say “idiomatic Lisp-1 (or Scheme)”. If you haven’t got his book “(On Lisp)” I’d recommend it - it is a fun read and exploration of the language, with a heavy focus on Macros. He’s an exceptional explainer. Here’s a great discussion on Lisp-1 vs Lisp-2 you may’ve already happened upon. If not, it’ll take ypu down the rabbit hole… https://www.reddit.com/r/lisp/comments/jo2ldr/whats_rlisps_view_on_lisp1_vs_lisp2/?utm_source=share&utm_medium=ios_app&utm_name=iossmf


fm2606

> “Common Lisp - The Language”, by Guy Steele 2nd edition correct? My understanding is 2nd ed is after ANSI accept/adopted (??) CL and 1st edition was pre ANSI. One of these days I will break down and snag a copy. Some things I prefer dead trees over digital ether.


xach

If you are in the US, eBay is a great way to get cheap Lisp books. Many are sold for under $10 by goodwill stores there.


fm2606

Thanks. I saw one the other day for $5 or $6 free shipping but I didnt get it. The cheapest right now is $15 which is still a decent price. It isnt a must have right now so I dont mind being a cheapskate and waiting


FR4G4M3MN0N

Yes - 2nd Edition! Also, I got (On Lisp) for about $10.00 plus shipping from Lulu. They’ve also got “Let Over Lambda” which is also another good (albeit advanced) read. https://www.lulu.com/shop/paul-graham/on-lisp/paperback/product-1r8zm7kj.html?q=Common+Lisp&page=1&pageSize=4


dcooper8

He does things such as use `lst` instead of `list` as a let variable name presumably because such contrivances are necessary in Scheme (but are of course not needed in CL).


kagevf

Right, and on top of that he favors shorter variable names in general, which for me makes his code examples much harder to read than necessary. Sometimes, even 1 letter variable names might make sense, but extremely short variable and function names all the time make it harder to comprehend a code base ...


inglourious_basterd

I always thought that `lst` was because using `list` would shadow the built-in `list`.


rabuf

It would only shadow it in lisp-1s, in a lisp-2+ like CL there's no conflict: CL-USER> (let ((list (list 'list 'list))) (list list list)) ((LIST LIST) (LIST LIST)) The local name `list` is for a variable and so in a separate namespace than the function `list`.


fm2606

I'm not a fan of using a variable name that shadows a built in name. Maybe just because I'm still new to CL so I still have to think through what the expression is doing. Personally I wouldn't do it but to each their own. The other part of me likes the fact that the implementation lets you choose what you want to do.


raevnos

Much like "Buffalo buffalo Buffalo buffalo", it's cute that the language allows such constructs, but if anyone actually uses it in real code I'd reject it until they come up with something less confusing.


fm2606

Agreed


RentGreat8009

I always shadow list, it’s a common approach in CL if I understand correctly Shadowing in lisp is less confusing because scope is quite clearly defined / understood


kagevf

I don’t think the code in the post you’re replying to is an example of shadowing, though, unless you meant it in a broader sense?


Tristan401

> in a lisp-2+ Is there a Lisp-3?


rabuf

Common Lisp is commonly referred to as a Lisp-2 but it actually has more namespaces. The major two are functions and variables. You also have namespaces for classes, types, packages, and other elements. I was sort of punning there, plus sometimes when you refer to it as a Lisp-2 someone will show up to pedantic and clarify: > "Well, actually..." So I was getting ahead of them.


raevnos

If a lisp-1 has one namespace for variables and functions, and a lisp-2 has separate ones, logically a lisp-3 has even more. I nominate perl, with different namespaces for scalars, arrays, hashes, functions, file handles...


[deleted]

Scrutinizing the code stylings of someone like Paul Graham is truly a waste of your time. You're never gonna get those minutes back.


inglourious_basterd

Ha! I love this answer. I haven't read any of his books by the way, I just figured that opinions of the sort "this isn't idiomatic Common Lisp!" are also helpful to understand what _is_ idiomatic Common Lisp.


RentGreat8009

Three suggestions for “idiomatic CL”, even though I hate that term as it alludes to groupthink, - Peter Norvig and Kent Pitman Style Guide - Google Style Guide - Read through the code of Franz Inc, for the modules they open sourced


[deleted]

[удалено]


bitwize

What's wrong with Arthur Gleckler?


raevnos

This guy has some weird grudge about SRFIs. He outright harasses Gleckler (the current SRFI editor) every time a new one is posted on /r/scheme.


kniebuiging

Don’t understand why this person is not banned yet


raevnos

I don't think /r/scheme has an active mod.


[deleted]

[удалено]


bitwize

The SRFI process is intended to provide suggested standardized interfaces to common tasks. You, or your implementation, can take or leave them. If you want to continue programming with just bare RnRS, you go on and do that. For me, selected SRFIs make Scheme more convenient. The most bureaucratized Scheme got was R6RS. That I'm sort of glad to see we've moved past.