Fixed suggested by -Wall -Wextra -pedantic
Marginally cleverer prealloc for tuples
Basic and very failing tests
First minor fixups to address test crashes