After checking the code carefully, I figured out the macro is wrong and the compiler error is correct. Apparently, other compilers do not catch this issue.
#define SNUM(x) static_cast<const std::ostringstream &>(std::ostringstream() << std::dec << x).str()
Post
Replies
Boosts
Views
Activity
@Etresoft, thanks for your reply. The example was just for demonstration, and It is not just this line that is failing.
It is not wise that I change lines of codes in other people's libraries.
If I understand you correctly, you say that this line of code is wrong and the CLANG error is correct!