Pure functions in D
Walter Bright
newshound1 at digitalmars.com
Fri Sep 26 17:01:10 PDT 2008
downs wrote:
> Just build a new executable, halt all your running tasks, dump the
> system state to a file (*including socket handles*), use the exec
> system call to replace the process with the new executable, and read
> the system state back, replacing handles as you go.
>
> No dropped connections.
I've done that with C/C++ code before. The trouble is finding *all* of
the state that matters in order to save/restore it. It can be done, but
it is tedious and very error prone.
But with pure functions, it's a no-brainer.
More information about the Digitalmars-d
mailing list