different inputs for different platforms
Part 1 refactor deserialization

passing tests
part 2 refactor serialization

compiles no checks yet
this was entered as optimization but is nonsense
part 3 refactor deserialization