1#include <c10/util/TypeCast.h>
2
3namespace c10 {
4
5void report_overflow(const char* name) {
6 std::ostringstream oss;
7 oss << "value cannot be converted to type " << name << " without overflow";
8 throw std::runtime_error(oss.str()); // rather than domain_error (issue 33562)
9}
10
11} // namespace c10
12