From: ·······@my-deja.com
Subject: Class Libraries in CLOS
Date: 
Message-ID: <8are10$2vn$1@nnrp1.deja.com>
Hello,
I'm new to Lisp and I come from a C++ background. I just started
learning CL (with ANSI Common Lisp) and was wondering if there's any
standard class library for CL (like the National Institute of Health
Class Library for C++) available out there.
I'm not sure if this is a C++ism, if it is, please forgive my
ignorance, I just don't want to reinvent the wheel... :)
Thanx


Sent via Deja.com http://www.deja.com/
Before you buy.

From: Stig E. Sandø
Subject: Re: Class Libraries in CLOS
Date: 
Message-ID: <87og8etx5h.fsf@palomba.bananos.org>
·······@my-deja.com writes:

> Hello,
> I'm new to Lisp and I come from a C++ background. I just started
> learning CL (with ANSI Common Lisp) and was wondering if there's any
> standard class library for CL (like the National Institute of Health
> Class Library for C++) available out there.
> I'm not sure if this is a C++ism, if it is, please forgive my
> ignorance, I just don't want to reinvent the wheel... :)

Common Lisp has several functions, macros and classes as part of it's
standard, just like C++ do.  The definite document of all these
classes, functions, macros, etc is the Common Lisp HyperSpec(tm) which
you might find at Xanalys' homepages:
http://www.xanalys.com/software_tools/reference/hyperspec.html

Good luck :-)

-- 
------------------------------------------------------------------
Stig Erik Sandoe     ····@ii.uib.no    http://www.ii.uib.no/~stig/
From: Pierre R. Mai
Subject: Re: Class Libraries in CLOS
Date: 
Message-ID: <873dpqft43.fsf@orion.dent.isdn.cs.tu-berlin.de>
·······@my-deja.com writes:

> Hello,
> I'm new to Lisp and I come from a C++ background. I just started
> learning CL (with ANSI Common Lisp) and was wondering if there's any
> standard class library for CL (like the National Institute of Health
> Class Library for C++) available out there.

The problem C++ suffered from (Bjarne Stroustroup pointed this out
repeatedly) was the lack of a decent standard library in its time
before the ISO standard.  As a direct consequence of this lack, you
were forced to either write a lot of support code from scratch before
starting to write any serious code, or to use one of the third-party
class libraries that were created to fill this need.

Common Lisp didn't have this problem, since most of the ANSI CL
standard is actually concerned with "library-style" functionality.  To 
put it into C++-like words:  CL already comes with a large built-in
standard library.  This "library" includes among other things:

- Usable (singly-linked) list and vectors, which are generalized into
  sequences and have a large array (no pun intended :) of standard
  functions to work on them (sorting, searching, mapping, reducing,
  changing, copying, etc.).  BTW: They all work on strings, because
  strings are just vectors of characters, and therefore sequences.

- Usable arrays, Hash-tables, Symbols, etc.

- Several different iteration constructs

- Non-basic I/O functionality (=> reader/printer)

- ...

For this reason, not very many third-party libraries for core
functionality were ever developed or needed...  Get yourself a copy of 
the HyperSpec[1], which you'll want to have anyway, and browse at your 
leisure for an overview of CL functionality.  You might also want to
take a look at http://www.alu.org/ for more information on many
aspects of CL.

> I'm not sure if this is a C++ism, if it is, please forgive my
> ignorance, I just don't want to reinvent the wheel... :)

Don't worry about it.  Take the time to learn CL, and you'll see that
most of the things provided by add-on libraries in other languages are 
already part of CL, or are made so easy/effortless to implement by CL
that making a general library out of this doesn't make any sense.
What you will find for CL are libraries and toolkits for specific
domain-specific higher-level constructs, like HTTP serving, database
accesses, persistent objects, knowledge representation, rule-based
reasoning, non-deterministic computation, etc.

Regs, Pierre.

Footnotes: 
[1]  The HyperSpec is a translation of the text of the ANSI CL standard to
     HTML done by Kent M. Pitman, then at Harlequin.  It can be accessed at
     http://www.xanalys.com/software_tools/reference/hyperspec.html for the 
     on-line copy and information on downloading a copy for use off-line. 

-- 
Pierre Mai <····@acm.org>         PGP and GPG keys at your nearest Keyserver
  "One smaller motivation which, in part, stems from altruism is Microsoft-
   bashing." [Microsoft memo, see http://www.opensource.org/halloween1.html]