5 ms·
How do you handle, say deserialization of objects over a network (to give the canonical non-trivial example)?
by KenoFischer 11y ago
How do you handle, say deserialization of objects over a network (to give the canonical non-trivial example)?
- eru 11y agoI don't know about Julia or Big Bang, but in Haskell your values conforming to types for serialization / deserialization would typical be checked once when parsing, and throw an error (or use a Maybe type) if anything is off.
- KenoFischer 11y agoYes, that's the standard approach, but I was wondering how that meshed with not having to declare types (maybe the answer is just, that's the one place where you have to - or that's disallowed), but I was curious.
- eru 11y agoIn Haskell, if you don't do anything weird, you don't have to declare types either in the norm case: it can all be inferred.