chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] Protocol Buffers for CHICKEN


From: Thomas Chust
Subject: Re: [Chicken-users] Protocol Buffers for CHICKEN
Date: Wed, 29 May 2013 13:27:22 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130510 Thunderbird/17.0.6

On 2013-05-29 13:11, Felix wrote:
> From: Thomas Chust <address@hidden>
>> [...]
>> during the CHICKEN spring thing in Cologne I started to work on a new
>> egg [1] implementing the protocol buffer [2] serialization format, which
>> is now in a usable and tested state.
>>
>> If you don't need or want to use a specific schema for your data, you
>> can use the protobuf egg as a generic serialization solution that
>> produces platform-independent binary representations of (almost) any
>> CHICKEN values:
> 
> Whoa! Incredible! Finally a decent serialization library. Is
> closure/continuation-serialization reliable? I did some simple stupid
> tests and at least serializing a continuation in csi produced an error
> due to a not-serializable port (which is understandable).
> [...]

Hello Felix,

closure serialization definitely works, I have tried round tripping
compiled and interpreted procedures with and without surrounding context
through serialize and deserialize and they are still functional after
reading them back in.

Continuations should work, too, but it is non-trivial to construct a
continuation that doesn't close over all sorts of crazy stuff like the
input ports from which the interpreter reads library files etc. Fiddling
around with green threads to delimit the continuations and using the
facilities to inject "external dependencies" into the serialization
context of protobuf should do the job, though.

Cheers,
Thomas


-- 
When C++ is your hammer, every problem looks like your thumb.




reply via email to

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