theta-idl icon indicating copy to clipboard operation
theta-idl copied to clipboard

Use Vector a instead of [a] in TH-generated types

Open TikhonJelvis opened this issue 2 years ago • 0 comments

Theta's Template Haskell code generates lists ([a]) in Haskell for Theta arrays. Lists are not efficient for storing large amounts of data in Haskell both in terms of space and time, so it would be better to use Vector instead.

Theta.Value uses Vector Value for arrays, so I'm honestly surprised that I didn't do the same thing for the Template Haskell code.

This would be a breaking change, so I won't do it until I have a clearer release process in place. Since it affects performance, I'll probably want to have some benchmarks before then as well so that I can measure the impact on reading/writing Avro.

TikhonJelvis avatar Mar 29 '22 21:03 TikhonJelvis