#include <type_traits>
template<typename T>
struct identity { using type = T; };
template<typename T>
using try_make_signed =
typename std::conditional<
std::is_integral<T>::value,
std::make_signed<T>,
identity<T>
>::type;
int main()
{
static_assert(std::is_same<try_make_signed<unsigned int>::type, int>::value, "!");
static_assert(std::is_same<try_make_signed<double>::type, double>::value, "!");
}
ICAgICNpbmNsdWRlIDx0eXBlX3RyYWl0cz4KCiAgICB0ZW1wbGF0ZTx0eXBlbmFtZSBUPgogICAgc3RydWN0IGlkZW50aXR5IHsgdXNpbmcgdHlwZSA9IFQ7IH07CgogICAgdGVtcGxhdGU8dHlwZW5hbWUgVD4KICAgIHVzaW5nIHRyeV9tYWtlX3NpZ25lZCA9CiAgICAgICAgdHlwZW5hbWUgc3RkOjpjb25kaXRpb25hbDwKICAgICAgICAgICAgc3RkOjppc19pbnRlZ3JhbDxUPjo6dmFsdWUsCiAgICAgICAgICAgIHN0ZDo6bWFrZV9zaWduZWQ8VD4sCiAgICAgICAgICAgIGlkZW50aXR5PFQ+CiAgICAgICAgICAgID46OnR5cGU7CgogICAgaW50IG1haW4oKQogICAgewogICAgICAgIHN0YXRpY19hc3NlcnQoc3RkOjppc19zYW1lPHRyeV9tYWtlX3NpZ25lZDx1bnNpZ25lZCBpbnQ+Ojp0eXBlLCBpbnQ+Ojp2YWx1ZSwgIiEiKTsKICAgICAgICBzdGF0aWNfYXNzZXJ0KHN0ZDo6aXNfc2FtZTx0cnlfbWFrZV9zaWduZWQ8ZG91YmxlPjo6dHlwZSwgZG91YmxlPjo6dmFsdWUsICIhIik7CiAgICB9Cg==