[plt-scheme] Issue with Output _cvector Types Held in Variables

From: Henk Boom (lunarc.lists at gmail.com)
Date: Thu Jan 29 15:09:11 EST 2009

2009/1/27 Eli Barzilay <eli at barzilay.org>:
> Defining something using syntax-id-rules is not going to work, you
> probably need to use `define-fun-syntax'.

Thanks for the help! For reference, this is what I can write:

#lang scheme/base
(require scheme/foreign)
(define-fun-syntax t (syntax-id-rules () (_ (_cvector o _int 4))))
(define test (get-ffi-obj 'printf #f (_fun t -> _void)))

This behaves exactly as if t were replaced by (_cvector o _int 4) in
the _fun binding.


Posted on the users mailing list.