File tree 2 files changed +24
-0
lines changed
include/nlohmann/detail/input
2 files changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -162,6 +162,18 @@ template<>
162
162
struct char_traits <signed char > : std::char_traits<char >
163
163
{
164
164
using char_type = signed char ;
165
+ using int_type = unsigned long ;
166
+
167
+ // Redefine to_int_type function
168
+ static int_type to_int_type (char_type c)
169
+ {
170
+ return static_cast <int_type>(c);
171
+ }
172
+
173
+ static int_type eof ()
174
+ {
175
+ return static_cast <int_type>(EOF);
176
+ }
165
177
};
166
178
167
179
// General-purpose iterator-based adapter. It might not be as fast as
Original file line number Diff line number Diff line change @@ -6239,6 +6239,18 @@ template<>
6239
6239
struct char_traits<signed char> : std::char_traits<char>
6240
6240
{
6241
6241
using char_type = signed char;
6242
+ using int_type = unsigned long;
6243
+
6244
+ // Redefine to_int_type function
6245
+ static int_type to_int_type(char_type c)
6246
+ {
6247
+ return static_cast<int_type>(c);
6248
+ }
6249
+
6250
+ static int_type eof()
6251
+ {
6252
+ return static_cast<int_type>(EOF);
6253
+ }
6242
6254
};
6243
6255
6244
6256
// General-purpose iterator-based adapter. It might not be as fast as
You can’t perform that action at this time.
0 commit comments