Re: Binary serialization of a struct

2017-12-08 Thread Daniel Kozak via Digitalmars-d-learn
You should use size_t instead of ulong, but on 32bit you would have still problem because you are trying assign 2^32 which is too big to hold in 32bit On Thu, Dec 7, 2017 at 11:42 PM, kdevel via Digitalmars-d-learn < digitalmars-d-learn@puremagic.com> wrote: > On Tuesday, 19 September 2017 at

Re: Binary serialization of a struct

2017-12-08 Thread Cym13 via Digitalmars-d-learn
On Saturday, 16 September 2017 at 13:15:54 UTC, Azi Hassan wrote: On Saturday, 16 September 2017 at 03:30:51 UTC, Joseph wrote: Are there any simple direct serialization libraries where I can mark elements of a class or struct that I want serialized with an attribute and it will take care of

Re: Binary serialization of a struct

2017-12-07 Thread kdevel via Digitalmars-d-learn
On Tuesday, 19 September 2017 at 06:32:52 UTC, Nordlöw wrote: I want something straight forward without allot of plumbing on my end. https://github.com/msgpack/msgpack-d I can't unittest my 32-bit code: $ MODEL=32 make -f posix.mak unittest [...] src/msgpack/packer.d(1139): Error: function

Re: Binary serialization of a struct

2017-09-19 Thread Nordlöw via Digitalmars-d-learn
On Saturday, 16 September 2017 at 03:30:51 UTC, Joseph wrote: Are there any simple direct serialization libraries where I can mark elements of a class or struct that I want serialized with an attribute and it will take care of all the rest(including recursive structures, arrays, etc) then

Re: Binary serialization of a struct

2017-09-19 Thread spring via Digitalmars-d-learn
On Saturday, 16 September 2017 at 03:30:51 UTC, Joseph wrote: Are there any simple direct serialization libraries where I can mark elements of a class or struct that I want serialized with an attribute and it will take care of all the rest(including recursive structures, arrays, etc) then

Re: Binary serialization of a struct

2017-09-16 Thread Sergei Degtiarev via Digitalmars-d-learn
On Saturday, 16 September 2017 at 03:30:51 UTC, Joseph wrote: Are there any simple direct serialization libraries... I want something straight forward without allot of plumbing on my end. You may also take a look at https://github.com/sdegtiarev/persistentObject This is small module for

Re: Binary serialization of a struct

2017-09-16 Thread Azi Hassan via Digitalmars-d-learn
On Saturday, 16 September 2017 at 03:30:51 UTC, Joseph wrote: Are there any simple direct serialization libraries where I can mark elements of a class or struct that I want serialized with an attribute and it will take care of all the rest(including recursive structures, arrays, etc) then

Binary serialization of a struct

2017-09-15 Thread Joseph via Digitalmars-d-learn
Are there any simple direct serialization libraries where I can mark elements of a class or struct that I want serialized with an attribute and it will take care of all the rest(including recursive structures, arrays, etc) then deserialize back in to the structs? I want something straight