Questions tagged [newlisp]

newLISP is an Open Source scripting language in the Lisp family of programming languages developed by Lutz Mueller and released under the GNU General Public License.

newLISP is an Open Source scripting language in the Lisp family of programming languages developed by Lutz Mueller and released under the GNU General Public License.

Because of its small resource requirements, newLISP is excellent for embedded systems applications. Most of the functions you will ever need are already built in. This includes networking functions, support for distributed and multicore processing, and Bayesian statistics.

http://www.newlisp.org/

19 questions
10
votes
1 answer

Does newLISP use garbage collection?

This page has been quite confusing for me. It says: Memory management in newLISP does not rely on a garbage collection algorithm. Memory is not marked or reference-counted. Instead, a decision whether to delete a newly created memory object is made…
user541686
  • 205,094
  • 128
  • 528
  • 886
4
votes
0 answers

What do you use newlisp for?

Do you use newlisp? What have you used it for?
cbo
  • 405
  • 4
  • 7
2
votes
2 answers

loop over characters in string, NewLISP

I need to loop over the characters in a given string--in Ruby, I'd do something like this: string = "blah" string.each_char do |c| puts c end How do I do this in newLisp?
Alexej Magura
  • 4,833
  • 3
  • 26
  • 40
1
vote
2 answers

How to bind a macro inside a lambda in newLISP?

So I have this function: (define (try try-block catch-block finally-block) ; Implements try/catch/finally like in most other languages ) for which I would like to create a "helper" macro that avoids the need for saying (lambda () ...) over…
user541686
  • 205,094
  • 128
  • 528
  • 886
1
vote
1 answer

Wrapping an application written with newLISP in a single executable OSX app

As far as i have found out, it's possible -- and allowed -- to "link" and distribute a newLISP script with the newLISP binary to create a single-file executable. Now i would like to do this for an application using the newLISP gui server, much like…
aurora
  • 9,607
  • 7
  • 36
  • 54
1
vote
1 answer

newLISP Invalid Function

I have a homework assignment where we need to write some functions in newLISP. I am running into an issue, so I made an example of the issue to see if anyone can help me out. The issue is that after a recursive function is over, it returns an ERR:…
bmb
  • 361
  • 2
  • 13
1
vote
3 answers

Finding the attributes of Chinese filenames using NewLISP?

The following NewLISP code shows me the file attributes of files under Win32. However, some of the filenames retrieved have Chinese characters in the name. When the GetFileAttributesA function encounters them, it gives me a -1 for the attribute. I…
bugmagnet
  • 7,631
  • 8
  • 69
  • 131
1
vote
1 answer

How to define a function to read a wordlist

I want to read a file which contains a list of words (one word per line) into a list. (define (read-wordlist myFile) (begin (set 'listA '()) (set 'in-file (open myFile "read")) (while (read-line in-file) (set 'listA (append…
z--
  • 2,186
  • 17
  • 33
1
vote
1 answer

The "Artful" Mysql module for newLisp does not connect to MySQL

I am trying out the Artful Mysql module with newLisp and the "smoke" test using the examples does not connect to MySQL. Assumptions: I am a newbie Lisp programmer. Platform is MacOS X 10.9 newLisp 10.6 MySQL 5.5 The newLisp 10.6 standard…
Michael Bartz
  • 269
  • 1
  • 3
  • 10
1
vote
1 answer

In newLISP, quote is different from '?

I begin to learn newlisp, but the quote and ' puzzle me. > (= '(quote 1) ''1) nil or > (first (quote (quote 1))) quote > (first ''1) ERR: array, list or string expected in function first : ''1 in newlisp, quote is different from ' ? or,…
skeu
  • 25
  • 3
1
vote
1 answer

Why does newLISP limit string literals to 2048 characters?

I'm trying to write usage instructions for this newLISP program I've made but it keeps complaining about the string being too long. ERR: string token too long : "$$$$$$$$&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&" I spent some ten minutes cursing newLISP…
Plakhoy
  • 1,846
  • 1
  • 18
  • 30
1
vote
1 answer

How to send byte array via TCP when using newLISP

I want to send two bytes which represent an unsigned short in big-endian to server via TCP. But net-send only supports string parameter. Could anyone tell me how to do this with newLISP?
Dean Chen
  • 3,800
  • 8
  • 45
  • 70
1
vote
2 answers

return a line of text if match found

I am having some trouble working out how to return a line of text if a match is found. (set 'wireshark "http://anonsvn.wireshark.org/wireshark/trunk/manuf") (set 'arptable (map (fn (x) (parse x " ")) (exec "arp -a"))) (define (cleanIPaddress x) …
beoliver
  • 5,579
  • 5
  • 36
  • 72
1
vote
2 answers

newLISP: modifying association list

I have a problem with modifying entries of an association list. When I run this code Example A (set 'Dict '(("foo" "bar"))) (letn (key "foo" entry (assoc key Dict)) (setf (assoc key Dict) (list key "new value"))) (println Dict) the…
Jakub M.
  • 32,471
  • 48
  • 110
  • 179
0
votes
1 answer

Read stdin to string in Newlisp

How do you read the entire contents of standard input into a string in Newlisp? (i.e the entire remaining contents after the current read position - this operation is commonly called "slurp file")
Lassi
  • 3,522
  • 3
  • 22
  • 34
1
2