How to free GPU memory of at::Tensor in ATen, C++?

I find that merely including this file leads to a compile error:

/home/dshin/libtorch/include/c10/cuda/CUDAStream.h: In constructor ‘c10::cuda::CUDAStream::CUDAStream(c10::Stream)’:
/home/dshin/libtorch/include/c10/cuda/CUDAStream.h:69:25: error: expected unqualified-id before ‘(’ token
   69 |     TORCH_CHECK(stream_.device_type() == DeviceType::CUDA);
      |                         ^~~~~~~~~~~

My build-version is 1.13.0+cu116.