We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a6b71df + 1447599 commit d892645Copy full SHA for d892645
include/cppflow/datatype.h
@@ -5,6 +5,12 @@
5
#ifndef CPPFLOW2_DATATYPE_H
6
#define CPPFLOW2_DATATYPE_H
7
8
+#include <type_traits>
9
+#include <string>
10
+#include <typeinfo>
11
+#include <ostream>
12
+#include <stdexcept>
13
+
14
namespace cppflow {
15
16
using datatype = TF_DataType;
@@ -96,7 +102,8 @@ namespace cppflow {
96
102
if (std::is_same<T, uint64_t>::value)
97
103
return TF_UINT64;
98
104
99
- throw std::runtime_error{"Could not deduce type!"};
105
+ // decode with `c++filt --type $output` for gcc
106
+ throw std::runtime_error{"Could not deduce type! type_name: " + std::string(typeid(T).name())};
100
107
}
101
108
109
/**
0 commit comments