
NewLisp - ecounysis
http://www.newlisp.org/
======
jules
Better spend your time learning Clojure, Racket, Scheme or Common Lisp.
NewLisp repeats the design mistakes of ancient Lisps that were fixed in the
newer Lisps, like dynamic scoping and interpreting only instead of compiling
which makes it much slower than other Lisps. NewLisp should be called OldLisp.
It also adds some mistakes of its own, like deep copying everything when you
pass it around. And making `cons` act like `list` when the second argument is
not a list.

~~~
oofoe
While it is true that NewLisp isn't going to win any awards from either the
Avant /or/ the Vieille Garde, I would argue that just because its philosophy
is different from what you believe is most performant doesn't make it a bad
language. Ruby's defenders should back me up on that...

As I understand it, scoping is handled by "contexts", which can be
inconvenient if you expect every function to be a single standalone snowflake,
but just fine if you`re tossing off quick scripts which don`t require hermetic
degrees of encapsulation. You can also force scope by using 'let' or declaring
private variables as arguments, among other things. Certainly Emacs Lisp seems
to do OK with similar constraints.

As mentioned elsewhere in this post, the deep copy thing may not be as bad as
you make it out to be -- certainly it's never particularly troubled me.

As for cons... It seems to me that cons is a rather obsolete construct,
referring to a long obsolesced hardware feature. I can't get too unhappy about
someone trying to make it more immediately useful in a modern context.

We've talked about what you don't like about it -- here's what I think NewLisp
has gotten very much right:

    
    
      * It's simple to use.
      * It's small and self contained.
      * It has a REPL and you can do introspection. 
      * It has conveniently and reasonably named built-in functions.
      * It deals well with a UNIX-derived file system.
      * It's easy to pick up and start using, but you can still do fancy stuff.
      * The documentation contains worked out examples for every built in function.
      * The main developer is very responsive and helpful.
      * Trivially cross-platform with downloads, not compiles.
    

I have found NewLisp to be very convenient for many of the problems I have
applied it to. I have used it for everything from dynamic web pages to image
processing to ad-hoc render farms. So, I certainly feel that it may be
invaluable for someone who is interested in Lisp, but has been intimidated or
discouraged by the "official" compilers and needs to get some real world work
done.

~~~
quanticle
Let me respond to your points individually:

>It's simple to use.

There are many Lisps that are simple and easy to use. Scheme, for one, is
extraordinary simple and easy to use. Indeed, many colleges use it for their
introduction to programming classes.

>It's small and self contained.

This could apply to any Lisp, but again is especially true of Scheme. Scheme
is a very small language; the entire language can be built from 7 special
forms. How much smaller can a language get? Even all the special forms
required to build a "practical" Lisp like Clojure can be counted on two hands.
Lisp, in general is a very elegant and self contained language. NewLisp's
elegance and cohesion does not break new ground.

>It has a REPL and you can do introspection.

Every Lisp extant today has these two features. Indeed, introspection is
inherent to all Lisps; when code is data and data is code, introspection
becomes trivial.

>It has conveniently and reasonably named built-in functions.

>It deals well with a UNIX-derived file system.

Most Lisps have fairly nice pre-built functions for accessing files. Moreover,
I don't want my programming language to become especially tied to a single
platform, by making file-system assumptions that may not hold true on other
systems.

>It's easy to pick up and start using, but you can still do fancy stuff.

Well, it is Lisp. The inherent abstraction of the language will mean that Lisp
won't ever be as "beginner-friendly" as, say, Python or Ruby. That said,
Scheme (especially Racket) does an incredibly good job of allowing total
novices to build programs in a very short time. As far "fancy stuff" goes, I
wrote a minimax chess engine with an interactive graphical front-end for a
school project. I don't know if that's fancy enough, but it certainly seemed
pretty cool at the time.

>The documentation contains worked out examples for every built in function.

Again. see Racket.

>The main developer is very responsive and helpful.

Well, here I must concede a point. I have no idea how responsive the
developers of Racket are, for I never had cause to contact them.

>Trivially cross-platform with downloads, not compiles.

First, this is true of every JIT compiled and interpreted language. Second,
its not as trivial as you're making it out to be. The user has to have the
interpreter installed, unless the interpreter, libraries and script are all
packaged together as a frozen binary of some sort.

~~~
Markku
> >The main developer is very responsive and helpful.

> Well, here I must concede a point. I have no idea how responsive the
> developers of Racket are, for I never had cause to contact them.

They are very responsive and helpful and the mailing list is active.

------
tsotha
_It is especially well-suited for applications in AI..._

<Groan>. I wish people would stop putting "lisp" and "AI" in the same
sentence. How many decades did lisp languish because people thought there was
no reason to learn it if they weren't doing AI?

~~~
Miky
And from the other side, how many decades was AI approached from an
ineffective direction because it was assumed that Lisp was good at it?

~~~
pangram
Your thesis here is that Lisp itself was a limiting factor in AI research?
What alternate language/direction would have resulted in substantially more
progress?

~~~
maaku
I'm not Miky, but I interpreted his statement to be that doing AI is a whole
heck of a lot more complicated than just using an introspective, code-as-data,
data-as-code language.

LISP is a hammer in an AI researcher's toolbox. Human-level AI is a monumental
skyscraper undertaking. For sure, any construction team would be hard-pressed
to build the Empire State Building without the proper tools, but there's a lot
more to it than that.

------
thurn
Can someone explain NewLisp's memory management model to me? The description
here: <http://www.newlisp.org/MemoryManagement.html> makes it sound like
NewLisp essentially uses something like an std::auto_ptr from C++ for all its
references, but I'm not sure how its possible to write a Lisp where you only
ever have one reference to things.

~~~
SoftwareMaven
It looks like everything is passed by value, so instead of passing a reference
to that int, string, list, array, etc, you are always passing a copy. Once you
hit an evaluation contact above where the copy cane from, it can be deleted.

I would imagine for some particular set of data (many large arrays and such)
that this could get really slow, but their claim is, at least in the general
case, it is faster to copy everything.

~~~
praptak
They also provide mechanisms to pass by reference. Default pass-by-copy with
specially enabled pass-by-reference is indeed the opposite from most other
languages do. I wonder how this interacts with things like memory paging and
CPU cache.

~~~
_delirium
Default pass-by-copy with specially enabled pass-by-reference isn't _that_
uncommon; it's how C++ works, for example.

------
GuidoS
When I read any well written Lisp code I feel my awareness of the subject gets
cleaner, sharper and lighter. I never experienced a similar thing with other
languages. I am not belittling them, or criticising. It is just a deep
personal feeling, that has been lasting since university times, back in the
90s.

I liked the code that I have seen at newlisp.org, newlisper.wordpress.com (for
example) and I am eager to see what I can do with it.

After reading so many pages (including this one), on so many sites, I have
decided that I will learn newlisp too.

