This is a trivial patch to get foreigners working on CHICKEN 6. The only change
is calling error instead of syntax-error in a couple places.
Diego
--- /home/dieggsy/.cache/basket/chicken-install/5.4.0/foreigners/foreigners.scm 2025-11-22 09:05:53.381438357 -0500
+++ /home/dieggsy/.cache/basket/chicken-install/5.4.0/foreigners6/foreigners.scm 2025-11-22 09:10:06.904376407 -0500
@@ -64,9 +64,10 @@
(let ((decl (caar slts)))
(cond ((c decl (r #:constructor)) (set! ctor (cadar slts)))
((c decl (r #:destructor)) (set! dtor (cadar slts)))
- (else (syntax-error 'define-foreign-record-type
- "invalid foreign record-type declaration" (car slts))) )) )
-
+ (else
+ (error 'define-foreign-record-type
+ "invalid foreign record-type declaration" (car slts))))))
+
(chicken.compiler.support#register-foreign-type! tname `(c-pointer ,fname))
(let ((%void 'void) ; foreign-lambda* recognizes renamed type identifiers now,
@@ -208,7 +209,7 @@
"error in enum spec" spec))
(s `((,s ,s) ,s ',s))
(else
- (syntax-error 'default-foreign-enum-type
+ (error 'default-foreign-enum-type
"error in enum spec" spec))))
enumspecs)))
(with-renamed