chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] call Chicken Scheme from C and pass a bytevector


From: Felix
Subject: Re: [Chicken-users] call Chicken Scheme from C and pass a bytevector
Date: Fri, 28 Jun 2013 13:49:10 +0200 (CEST)

> Actually, the bytes should probably be allocated in the structure,
> right?
> 
>   struct ipv4_addr_struct {
>     C_header tag;
>     uint8_t octets[4];
>   };
>   typedef struct ipv4_addr_struct ipv4_addr;
> 
>   static const C_header BTREE_TAG =
>     ((sizeof(ipv4_addr) - sizeof(C_header)) /
>     sizeof(C_word)) | C_BYTEVECTOR_TYPE;

This would be a "blob" (or bytevector), right.


cheers,
felix



reply via email to

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