Guard the debug temp variable with NDEBUG to avoid warning/error with NDEBUG defined.