From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 7934) id B6FD93858D39; Sat, 8 Jul 2023 05:54:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B6FD93858D39 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1688795649; bh=x8y5+vW1h5/8WN4rZ+YMCRB2wYroSKZv9LvfucV8XU8=; h=From:To:Subject:Date:From; b=pea7oee7bE/Nm8P++CH/AksoNKyYgf16X3lW51YA9wYrJ/LcUYfrxDttAcXJpYoG9 c5sBPWCnshYNrsn4oiMNBvVM6yvAS1BMoEN58vBzFEyZtAWbXPKyYyK1AjUNMOinGI Md1vmJqK50dSxDSpz+PztZvUI7f0FepjMxebBDkE= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Ken Matsui To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc(refs/users/kmatsui/heads/is_unsigned)] libstdc++: use new built-in trait __is_unsigned X-Act-Checkin: gcc X-Git-Author: Ken Matsui X-Git-Refname: refs/users/kmatsui/heads/is_unsigned X-Git-Oldrev: e49563f190fa0ccea6227321667da455644d9939 X-Git-Newrev: 9c1ac3067379c3d2e8021969045843d68ea95f3b Message-Id: <20230708055409.B6FD93858D39@sourceware.org> Date: Sat, 8 Jul 2023 05:54:09 +0000 (GMT) List-Id: https://gcc.gnu.org/g:9c1ac3067379c3d2e8021969045843d68ea95f3b commit 9c1ac3067379c3d2e8021969045843d68ea95f3b Author: Ken Matsui Date: Tue Mar 21 09:58:00 2023 -0700 libstdc++: use new built-in trait __is_unsigned This patch lets libstdc++ use new built-in trait __is_unsigned. libstdc++-v3/ChangeLog: * include/std/type_traits (is_unsigned): Use __is_unsigned built-in trait. Signed-off-by: Ken Matsui Diff: --- libstdc++-v3/include/std/type_traits | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/libstdc++-v3/include/std/type_traits b/libstdc++-v3/include/std/type_traits index 0e7a9c9c7f3..c56684d7bd8 100644 --- a/libstdc++-v3/include/std/type_traits +++ b/libstdc++-v3/include/std/type_traits @@ -884,10 +884,17 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION { }; /// is_unsigned +#if __has_builtin(__is_unsigned) + template + struct is_unsigned + : public __bool_constant<__is_unsigned(_Tp)> + { }; +#else template struct is_unsigned : public __and_, __not_>>::type { }; +#endif /// @cond undocumented template