On 2016-07-18 17:17, kact...@gnu.org wrote:
From: Dmitry Bogatov <kact...@gnu.org>
Document '<foreign-type>' record type and 'define-foreign-type'
procedure.
Can you compare this 'foreign-type' library with scheme-bytestructures
[0]. How
can both libraries help each other? Work hand in hand?
[0] https://github.com/TaylanUB/scheme-bytestructures
Tell me if I'm wrong but it looks like you have to define validate,
encode
and decode proc for every single structure with no helpers. It seems to
me
that it's some kind of framework for doing validation of static typed
procedures
which also handles automatic conversion between C land and scheme land.
Honestly this is not the kind of library I would use, I seldom do input
validation
when the client of my program is a developer. Maybe I'm wrong but IMO
dynamic languages
help that.
Also based on my small experience of ffi, there is not much conversion
to do between
scheme and C and what's best is to avoid any copy which is what does
scheme-bytestructures.
WDYT?
Thanks!
--
Amirouche ~ amz3 ~ http://www.hyperdev.fr