persistence: deal with typed arrays