Simplify typed array creation code in MEMFS.