Re: Interpreter tutorial error

2021-07-18 Thread Mario Domenech Goulart
Hi,

On Sun, 18 Jul 2021 17:30:14 +0200 (CEST) ammkrn--- via 
 wrote:

> I'm reading the Chicken Scheme manual's section on using the
> interpreter. The first code example, under "Writing Sheme Scripts"
> doesn't seem to work with csi Version 5.2.0 (rev 317468e4)
> macosx-unix-clang-x86-64 [ 64bit dload ptables ].
>
> When I follow the instructions, I get the error below. If someone
> could let me know what I'm doing wrong, I would appreciate it:
>
> Error: unbound variable: with-input-from-string
>
> Call history:
>
>(##sys#load-library (##core#quote library))
>(##sys#load-library (##core#quote expand))
>(import (chicken process-context))
>(##core#begin (##core#require library chicken.process-context#))
>(##core#require library chicken.process-context#)
>(##sys#load-library (##core#quote library))
>(##core#quote library)
>(##sys#load-library (##core#quote library))
>(print (eval (with-input-from-string (car 
> (command-line-arguments)) read)))
>(eval (with-input-from-string (car (command-line-arguments)) read))
>(with-input-from-string (car (command-line-arguments)) read)
>(car (command-line-arguments))
>(command-line-arguments)
>(print (eval (with-input-from-string (car (command-line-arguments)) 
> read)))
>(eval (with-input-from-string (car (command-line-arguments)) read))
>(with-input-from-string (car (command-line-arguments)) read) <--

Thanks for reporting that.  The manual was missing `(import (chicken port))'
in those examples.  I've fixed them.

All the best.
Mario
-- 
http://parenteses.org/mario



Interpreter tutorial error

2021-07-18 Thread ammkrn--- via
Hi,

I'm reading the Chicken Scheme manual's section on using the interpreter. The 
first code example, under "Writing Sheme Scripts" doesn't seem to work with csi 
Version 5.2.0 (rev 317468e4) macosx-unix-clang-x86-64 [ 64bit dload ptables ].

When I follow the instructions, I get the error below. If someone could let me 
know what I'm doing wrong, I would appreciate it:

Error: unbound variable: with-input-from-string

Call history:

    (##sys#load-library (##core#quote library))
    (##sys#load-library (##core#quote expand))
  (import (chicken process-context))
  (##core#begin (##core#require library 
chicken.process-context#))
  (##core#require library chicken.process-context#)
  (##sys#load-library (##core#quote library))
  (##core#quote library)
    (##sys#load-library (##core#quote library))
  (print (eval (with-input-from-string (car 
(command-line-arguments)) read)))
  (eval (with-input-from-string (car (command-line-arguments)) 
read))
  (with-input-from-string (car (command-line-arguments)) read)
  (car (command-line-arguments))
  (command-line-arguments)
    (print (eval (with-input-from-string (car (command-line-arguments)) 
read)))
    (eval (with-input-from-string (car (command-line-arguments)) read))
    (with-input-from-string (car (command-line-arguments)) read)  <--