pathnames [Re: files, printers, etc. [Re: The feel of a Lisp

Alaric B. Williams alaric@abwillms.demon.co.uk
Sat, 10 May 1997 10:49:45 +0000


> Alaric B. Williams:
> ;; (*employees* 'pictures #(picture of Lionel))
> ;; (*employees* 'names "Lionel B. Snell")
> ;; (*employees* 'surname "Snell"
 
> ;; Those are source code. My syntax is designed as what the user types in - 
 
> Trust me - if that's a syntax for an end-user (i.e. NOT a lisp
> programmer), users won't want to go anywhere near the machine.
> 
> An end-user is not going to be able to make sense out of that - they
> don't want to know LISP quoting rules, and they probably don't want to
> know LISP syntax at all.

Perhaps middle-user is the right term - the kind of person
who would use UNIX shells. Indeed, a true end-user would,
like you say below, never touch pathnames!
 
> #/employees/Snell/surname
> #/employees/LionelBSnell/picture

In this case, the employees database filer has to register itself
with the pathname manager, rather than just leave a "path" object
in the user repl environment called *employees*. Which has it's
pros and cons.

But to define a more formal semantics, a filer registers itself by
putting a path object in the appropriate environment such that it
reads it's arguments from left to right as a hierarchical subdivision
of itself, which may even be cyclic.

Thus, the syntax isn't unusual. We still quote symbols, unless we
/mean/ a variable reference.

The make-path function looks at a list, which must start with a path object,
and passes the rest of the list to the dereferencing function in the path 
object, and returns the result, which is another path object.

(make-path (*employees* ...))

is the Lisp source to parse said path.

> #R"/employees/by-surname/Snell".

That's a string. Representing things as strings when they are really lists
is a UNIX trick :-(
 
> Better yet, don't make them type paths at all. Write an integrated
> file system/OOFS/POS/Object browser with drag and drop. I almost never
> type paths by hand anymore in my everyday computer usage.

Me too, but the underlying CLI thing is important for Real Men (tm) to
use, too.

ABW
--
Alaric B. Williams (alaric@abwillms.demon.co.uk)

   ---<## OpenDOS FAQ ##>---

Plain HTML: http://www.delorie.com/opendos/faq/
            http://www.deltasoft.com/faq.html

Fancy HTML: http://www.deltasoft.com/faq0000.html