sharkdp / dbg-macro

A dbg(…) macro for C++
MIT License
2.97k stars 257 forks source link

Report a compiling error with old GCC version (GCC 4.8.5) #134

Closed pagesus closed 9 months ago

pagesus commented 10 months ago

I try to apply dbg-macro to my old project, using gcc 4.8.5 to compile the code, but failed. In error message, I guess maybe is SFINAE fialed, then follow the guide from https://en.cppreference.com/w/cpp/types/void_t

C++11_defect

I use the

template<typename... Ts>
struct make_void { typedef void type; };

template<typename... Ts>
using void_t = typename make_void<Ts...>::type;

to replace the definition in dbg.h's, then every thing is OK.

template <typename...>
using void_t = void;

I report this compiling error here, if some one have same problem, may this can be a help. :-D

sharkdp commented 9 months ago

Thank you.