News for hackers. Stuff that matters.
Re:Getting Started with Lisp (2019) by sn41 on Monday December 21, 2020 @11:19AM (#25496257)
Please take a look at Lisp macros. I finally got it at some point. It is a way of generating code on the fly. After I understood under what circumstances macros can abbreviate code, every other language will look unnecessarily verbose.

This is enabled by the fact that code in Lisp is also written in the form of lists. Code is data, data becomes code if you write a macro to process the data.

For example, is the following data or code?

(book (author "Jonathan swift") (title "A Modest Proposal"))

It definitely looks like data. But it can be made into code using an appropriate macro.

What probably Lisp trails in is type inference and bleeding edge libraries.

Re:Getting Started with Lisp (2019) by cat199 on Monday December 21, 2020 @01:30PM (#25497802)
> It definitely looks like data. But it can be made into code using an appropriate macro.

to chime in, it also can be made into 2 systems - one which defines 'book' as an in-memory object which can be inspected, and one which, say, defines a remote database object - your 'language spec' is the syntax, and you can implement multiple implementations, or replace subsystems as you build up the bigger thing - e.g. 'now my hashtables are persisted to disk', etc

Re:Getting Started with Lisp (2019) by phoe-krk on Monday December 21, 2020 @11:24AM (#25496324)
> What probably Lisp trails in is type inference

SBCL type inference is actually getting better and better over time, giving you pretty effective gradual typing. Additionally, a Common Lisp implementation called SICL is in the works, with an advanced compiler and type inference engine.

https://github.com/robert-strandh/SICL/