You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey,
while installing the library in my project i got 2 compiler warnings due to my pedantic settings ("/W4" under Windows, "-Wall -Wextra -Werror -Wno-long-long -Wpedantic" under linux).
It would be cool if you could fix them in the original code, this is the diff i used to fix both errors, however you should have a brief look the solution because i just started working with c++:
1st Error: compiler warning because of possible lost of data when converting size_t to unsigned
2nd Error: isspace returns an int, but the function should return a bool
backward.hpp
@@ -435,7 +435,7 @@ struct Trace {
addr(0), idx(0) {}
explicit Trace(void* addr, size_t idx):
- addr(addr), idx(idx) {}
+ addr(addr), idx(unsigned(idx)) {}
};
struct ResolvedTrace: public Trace {
@@ -1520,7 +1520,7 @@ public:
// What a good boy am I.
struct isspace {
bool operator()(char c) {
- return std::isspace(c);
+ return std::isspace(c) != 0;
}
};
The text was updated successfully, but these errors were encountered:
Hey,
while installing the library in my project i got 2 compiler warnings due to my pedantic settings ("/W4" under Windows, "-Wall -Wextra -Werror -Wno-long-long -Wpedantic" under linux).
It would be cool if you could fix them in the original code, this is the diff i used to fix both errors, however you should have a brief look the solution because i just started working with c++:
1st Error: compiler warning because of possible lost of data when converting size_t to unsigned
2nd Error: isspace returns an int, but the function should return a bool
The text was updated successfully, but these errors were encountered: