c42f / tinyformat

Minimal, type safe printf replacement library for C++
531 stars 75 forks source link

const std::atomic actual parameter with requested alignment of 8 won't be aligned #47

Closed shafeng closed 6 years ago

shafeng commented 6 years ago

when i use tinyformat in vs2015,this line was error:

sizeof(tryConvert(makeT1())) == sizeof(succeed);

error C2178 const std::atomic actual parameter with requested alignment of 8 won't be aligned

how to fix it?

shafeng commented 6 years ago

line number is :201

c42f commented 6 years ago

The line you're having trouble with inside is_convertible was a hack required for compilers which are quite old now. C++11 supplies the <type_traits> header, including std::is_convertible, so you could try removing is_convertible and using std::is_convertible?

shafeng commented 6 years ago

@c42f Thank you , Maybe my C++ compiler without C++11 support