Mind reviewing this? It seems to be performance neutral, but adds extra checks to prevent this struct from being accessed off the stack