Shalom, Zheng.
ZL> Instead, I got a question for the list: since the
ZL> runtime can judge whether a value contains functional
ZL> value and should be marshaled with closure, why does it
ZL> require the programmers to write that ?
"Semantic" reason: sometimes programmer wants to read
marshalled datastructures using another program, and when
programmer doesn't specify flag "Closures", he is sure that
function values won't be serialized and mashalled data will
be read successfully.
(of course, when marshalling algorithm remains fixed)
Sometimes I used marshalling to check whether my
data structure contains functional values or not, and
sometimes I prevented marshalling of some data structures
by including any functional value in it. So, "Closures"
flag is very useful for me.
"Effectiveness" reason #1: marshalling functional value
requires computation of MD5 hash of program, which requires
some time (computation is performed once per program run,
so it is not very time-consuming).
"Effectiveness" reason #2: each functional value uses
additional 16 bytes of serialized data to store MD5 of
program.
--
WBR,
dmitry mailto: gds-mlsts%40moldavcable.com">gds-mlsts
moldavcable.com
.