[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] C printf ffi

From: felix
Subject: Re: [Chicken-users] C printf ffi
Date: Wed, 10 Jul 2002 18:41:24 +0200

> How would one go about creating a ffi to something like printf?

Currently not. The problem is that the compiler has to check the arguments
(in safe code we don't want it to crash). So all arguments types have to
be known in advance. A `printf()' style argument list can contain arguments
all possible types. In C you have a canonical way of passing arguments of
unknown type, but in Chicken it is not possible. One could extend the
`foreign-lambda...' forms to accept rest-parameter lists, but those would be
restricted to a single argument type.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]