RFC open on newLISP documentation

Notices and updates
Locked
nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

The syntax entry for (float in manual still says
str must start with space(s), a number digit or the + or - sign.
when starting with decimal point is now valid viz
> (float ".5")
0.5

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

Also -.5 is a valid C float viz
#include <stdio.h>
int main () {
double f;
f = -.5;
printf("%g\n",f);
}
compiles with gcc
but

> (float ".5")
0.5
> (float "-.5")
nil
> (float "-0.5")
-0.5
>

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

this will be changed, there is also a new chapter in the docs about syntax of variable names and numbers

Lutz

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

I had to roll back one of the changes in 7.5.9 and posted a 7.5.10 this morning: http://newlisp.org/download/development/

Lutz

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

Still fixing constant protection and iteration, protection inside 'dotimes and 'for also rolled back in 7.5.11:

http://newlisp.org/download/development/

Lutz

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

and more constant 'trauma', version 7.5.12

http://newlisp.org/download/development/

Lutz

ps: I'll try to make this the last one today :)

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

For the new syntax section can I suggest rather than

"Integers start with a + or - sign followed by a number of digits from 0 to 9. Any other character will makr the end of a number."

the text (or similar):

Integers are one or more digits, optionally preceeded by a + or - sign. Any other character will mark the end of the integer or may be part of the sequence if parsed to a float (see float syntax below).

The last sentence is because
> (parse "1E")
("1" "E")
> (parse "1E1")
("1E1")
>

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

A request:
could the alphabetic access links
viz:
Functions in alphabetical order
!+-*/<>= A B C D E F G I J L M N O P Q R S T U W X
be placed into the manual so that it is on screen when the manual is first called up (in 'standard' res on 800x600 screen say).
I call up help and see the manual title splash (again) then have to start scrolling around to find the function links.
I suggest maybe placing just under
"newLISPtm
For LINUX, FreeBSD, Mac OSX, Solaris and Win32
Users Manual and Reference v.7.5.12"
and before the
"Copyright © 1991-2004 Lutz Mueller. www.nuevatec.com. All rights reserved."
then it would be immediately visible.

Nigel

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

The next manual will have a link to itself where it says: "Functions in groups"

You bookmark this and it will position the functions group list with the alphabetical index underneath fitting on smaller screens.

Lutz

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

I know some people HATE frames, BUT, when they are done properly ...

You could have a frame with the index at the top or the side. The docs that come with Java use this method, although you have to go through trees of information with all the classes they have. An index at the side, sure would make navigating the commands easier.

Eddie

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

Lutz, if you would like me to make the three frames, frameset, index, and body. I would be glad to do it and e-mail them to you.

Eddie

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

If this could be done in a way where newlisp_manual.html doesn't need to change, that would be fantastic! So we would have two additional files (1) the manual_frame.html and (2) newlisp_index.html.

Thanks

Lutz

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

Done!

Eddie

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

Beautiful, thankyou, it is online here:

http://newlisp.org/download/development ... frame.html

Lutz

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

I like it - thanks

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

things where misssing in the index and some other small fixes in the manual, now rev-2:

http://newlisp.org/download/development ... frame.html

Lutz

eddier
Posts: 289
Joined: Mon Oct 07, 2002 2:48 pm
Location: Blue Mountain College, MS US

Post by eddier »

Oops! What did I leave out of the index?

Eddie

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

No problem, it was from version 7.3.x and missed 'source' and the array section.

Lutz

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

correction : index item for date is:
Time and date functions
date return the current date and time in a string

should say something like:

Time and date functions
date converts a data-value type integer to date and time in a string form

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

Re documentation of cammandline -
I've noted where doit.lsp is (println "hello there") that:
C:\newlisp>newlisp doit.lsp -e "(println 10)"
hello there
10
10
C:\newlisp>newlisp -e "(println 10)" doit.lsp
10
10

That is, newlisp will do lisp files if they are before the -e directive

I'll change the man page synopsis section to reflect that.

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

The way the code works is, taking each option one by one, so you could have lisp files before and after the options. The -p -d options are special in the sense that they hang in the first connection.

Lutz

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

If options are taken in order could we have one like -e but that doesn't exit on completion but is like a file in that position so you could do (if it was say -l for lisp)
newlisp -l "(println {doing file 1})" file1.lsp -l "(println {doing file 2})" file2.lsp -e "(println {completed, exiting})"

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

Too much code to for a little feature, which can easily be achieved otherwise, i.e. putting those message in the files themselves or writing a shell script.

Lutz

nigelbrown
Posts: 429
Joined: Tue Nov 11, 2003 2:11 am
Location: Brisbane, Australia

Post by nigelbrown »

Fair enough

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

BTW you can also put several expressions in to the -e :

newlisp -e "(dothis) (load {somefile.lsp}) (dothat) (etc)"

of course 'somefile.lsp' should not and with (exit)

Lutz

Locked