Throw and error if we try to read past the end