chicken-users:
I am Chicken noob with (e-mail addresses redacted):
2019-09-17 22:06:21 root@tinkywinky ~
# cat /etc/debian_version
9.11
2019-09-17 22:10:03 root@tinkywinky ~
# uname -a
Linux tinkywinky 4.9.0-11-amd64 #1 SMP Debian 4.9.189-3 (2019-09-02)
x86_64 GNU/Linux
2019-09-17 22:15:35 root@tinkywinky ~
# dpkg-query -s chicken-bin
Package: chicken-bin
Status: install ok installed
Priority: optional
Section: lisp
Installed-Size: 5765
Maintainer: Davide Puricelli (evo) <x...@xxxxxx.xxx>
Architecture: amd64
Source: chicken
Version: 4.11.0-1
Replaces: chicken, chicken-dev
Depends: libc6 (>= 2.4), libchicken8 (>= 4.11.0), libchicken-dev (=
4.11.0-1)
Conflicts: chicken, chicken-dev
Description: Practical and portable Scheme system - compiler
CHICKEN is a Scheme compiler which compiles a subset of R5RS into C.
It uses the ideas presented in Baker's paper "Cheney on the MTA", and
has a small core and is easily extendable.
.
This package contains the compiler.
Homepage: http://www.call-cc.org
I am attempting to follow:
http://wiki.call-cc.org/man/5/Getting%20started
I have created a Scheme program source file:
2019-09-17 22:07:12 dpchrist@tinkywinky ~/sandbox/chicken-scheme
$ cat palindrome.scm
;;; http://wiki.call-cc.org/man/5/Getting%20started
;;; downloaded 2019-09-17
(import (chicken process-context)) ; for "command-line-arguments"
(define (palindrome? x)
(define (check left right)
(if (>= left right)
#t
(and (char=? (string-ref x left) (string-ref x right))
(check (add1 left) (sub1 right)))))
(check 0 (sub1 (string-length x))))
(let ((arg (car (command-line-arguments))))
(display
(string-append arg
(if (palindrome? arg)
" is a palindrome\n"
" isn't a palindrome\n"))))
When I try to compile:
2019-09-17 22:07:15 dpchrist@tinkywinky ~/sandbox/chicken-scheme
$ csc -o palindrome palindrome.scm
Syntax error (import): cannot import from undefined module
process-context
Expansion history:
<syntax> (##core#begin (import (chicken process-context)))
<syntax> (import (chicken process-context)) <--
Error: shell command terminated with non-zero exit status 17920:
'/usr/bin/chicken' 'palindrome.scm' -output-file 'palindrome.c'
I appear to be missing the module "chicken process-context", which is
supposed to be included (?):
http://wiki.call-cc.org/man/5/Included%20modules
Suggestions?
David
_______________________________________________
Chicken-users mailing list
Chicken-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/chicken-users