]> gcc.gnu.org Git - gcc.git/commit
libstdc++: Optimize is_void and is_null_pointer
authorPatrick Palka <ppalka@redhat.com>
Wed, 7 Sep 2022 14:21:45 +0000 (10:21 -0400)
committerPatrick Palka <ppalka@redhat.com>
Wed, 7 Sep 2022 14:21:45 +0000 (10:21 -0400)
commit66af6e991bf0daf1c41e46400a8f19e87c358cf2
tree93c355e894f77239c489beda6bcdf2f94074e160
parent873d395c2976a8321cec03f21d77e11f746da7c0
libstdc++: Optimize is_void and is_null_pointer

Instead of defining these in terms of a helper class template
and the relatively expensive __remove_cv_t, just declare four
explicit specializations of the main template, one for each choice
of cv-quals.

libstdc++-v3/ChangeLog:

* include/std/type_traits (__is_void_helper): Remove.
(is_void): Make the primary template derive from false_type,
and define four explicit specializations that derive from
true_type.
(__is_null_pointer_helper, is_null_pointer): Likewise.
libstdc++-v3/include/std/type_traits
This page took 0.059925 seconds and 6 git commands to generate.