everything compiles again
based on repa-branch of primitivearrays
some helper functions added