On 5/30/2010 6:38 AM, Robert wrote:
Hi, are there are any projectes / snippets / prototypes where someone
tried to serializa D run-time data-structures (like an associative
array) into a file?
--
Robert M. Münch
http://www.robertmuench.de
After having difficulty getting ddbg to work, I decided to write a dump
function so I could easily see my data structures at runtime. The
biggest part of it is a json encoder which can handle most D structures.
If I recall, it only has trouble with enum's and pointers (since
there's no length info).
It's available in Yage's source here
(http://dsource.org/projects/yage/browser/trunk/src/yage/core/json.d)
Yage is licensed LGPL but I grant permission to use this under the Boost
1.0 license if you or anyone else needs it.
However, for now it's only one-way and there's no deserialization part
to it.