Re: [O] [babel] What is `, (backquote comma)?
On 21 Sep 2011, at 21:48, Jambunathan K wrote: I learnt more about all the strange looking `', creatures by cursorily reading the first link and casually looking at the flip-flop diagram seen on the second link. http://www.lisperati.com/syntax.html http://www.lisperati.com/looking.html I am surprised that a book that seems so playful could convey a fundamental/foundational idea in such simple and succinct terms. I can heartily recommend the book “Land Of Lisp”, by the same author. Cheers, Peter -- You can use an eraser on the drawing table, or a sledge hammer on the construction site. — Frank Lloyd Wright
Re: [O] [babel] What is `, (backquote comma)?
Thorsten quintf...@googlemail.com wrote: Hi List, in org-babel-expand-body:scheme (and e.g. org-babel-expand-body:emacs-lisp) I encounter something like this: (lambda (var) (format %S (print `(,(car var) ',(cdr var) While this part `(,(car var) ...) is explained in the manual (backquote and unquote), this part `(... ',(cdr var)) is a bit mysterious to me, and I do not find information about backquote( ... backquote comma ()) in the manuals or the web. Is that Emacs Lisp? What does that mean? If you write it like this: `(,(car var) (quote ,(cdr var))) does it become clearer? This form is equivalent to the previous one. Nick
Re: [O] [babel] What is `, (backquote comma)?
Štěpán Němec step...@gmail.com writes: On Wed, 21 Sep 2011 19:37:42 +0200 Thorsten wrote: in org-babel-expand-body:scheme (and e.g. org-babel-expand-body:emacs-lisp) I encounter something like this: (lambda (var) (format %S (print `(,(car var) ',(cdr var) While this part `(,(car var) ...) is explained in the manual (backquote and unquote), this part `(... ',(cdr var)) is a bit mysterious to me, and I do not find information about backquote( ... backquote comma ()) in the manuals or the web. Is that Emacs Lisp? What does that mean? Note it's not `,, which would indeed be a no-op, but ',, which here means evaluate the form after , and quote the result, IOW, the ' is just left there (for the same reason you also get to see the even more funny-looking `', and other variations sometimes). Really nothing new if you've read the backquote section of the Elisp manual. thanks Nick and Stepan, evaluate the form after , and quote the result that made me understand what its all about. I just read the backquote section Elisp manual, it does not cover these strange combiniations of barely distinguable characters, but I may haved missed it - its a thick book. Cheers Thorsten
Re: [O] [babel] What is `, (backquote comma)?
On Wed, 21 Sep 2011 21:05:12 +0200 Thorsten wrote: thanks Nick and Stepan, evaluate the form after , and quote the result that made me understand what its all about. I just read the backquote section Elisp manual, it does not cover these strange combiniations of barely distinguable characters, but I may haved missed it - its a thick book. You haven't missed anything. My point was that the pieces are all there -- as Nick pointed out by the rewriting, 'foo is just a convenient read syntax for (quote foo), so there's nothing special or new about `',foo, it's still manipulating a list structure in a way the manual describes. I'm sure you can find more resources on the net, as the same notation is used in other Lisps, in particular Common Lisp and Scheme. Two examples I know of: http://www.lispworks.com/documentation/HyperSpec/Body/02_df.htm http://bc.tech.coop/blog/041205.html (And by the way, if you really find ' and ` barely distinguishable, perhaps you might consider using another font? It's an important distinction to make, as you've now found. ;-)) -- Štěpán
Re: [O] [babel] What is `, (backquote comma)?
I learnt more about all the strange looking `', creatures by cursorily reading the first link and casually looking at the flip-flop diagram seen on the second link. http://www.lisperati.com/syntax.html http://www.lisperati.com/looking.html I am surprised that a book that seems so playful could convey a fundamental/foundational idea in such simple and succinct terms. IMO, Elisp manual is too dense here to be really useful. Jambunathan K. --
Re: [O] [babel] What is `, (backquote comma)?
another, post-el.On Wed, 21 Sep 2011, ?t?p?n N?mec wrote: On Wed, 21 Sep 2011 21:05:12 +0200 Thorsten wrote: thanks Nick and Stepan, evaluate the form after , and quote the result that made me understand what its all about. I just read the backquote section Elisp manual, it does not cover these strange combiniations of barely distinguable characters, but I may haved missed it - its a thick book. You haven't missed anything. My point was that the pieces are all there -- as Nick pointed out by the rewriting, 'foo is just a convenient read syntax for (quote foo), so there's nothing special or new about `',foo, it's still manipulating a list structure in a way the manual describes. I'm sure you can find more resources on the net, as the same notation is used in other Lisps, in particular Common Lisp and Scheme. Two examples I know of: http://www.lispworks.com/documentation/HyperSpec/Body/02_df.htm http://bc.tech.coop/blog/041205.html (And by the way, if you really find ' and ` barely distinguishable, perhaps you might consider using another font? It's an important distinction to make, as you've now found. ;-)) Jude jdash...@shellworld.net I love the Pope, I love seeing him in his Pope-Mobile, his three feet of bullet proof plexi-glass. That's faith in action folks! You know he's got God on his side. ~ Bill Hicks