/is_member_function_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 176 +-
gcc/cp
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_arithmetic.
* g++.dg/ext/is_arithmetic.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 15 ++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 7fd29d8d9f2..d7f89cf7c06 100644
--- a/libstdc++-v3/include
This patch optimizes the performance of the is_reference trait by dispatching
to the new __is_reference built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_reference): Use __is_reference built-in
trait.
(is_reference_v): Likewise.
Signed-off-by: Ken
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_bounded_array.
* g++.dg/ext/is_bounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
This patch optimizes the performance of the is_volatile trait by dispatching
to the new __is_volatile built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_volatile): Use __is_volatile built-in
trait.
(is_volatile_v): Likewise.
Signed-off-by: Ken Matsui
(trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_array.
* g++.dg/ext/is_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp
.
(is_member_object_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 17 -
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index e1b10240dc2..792213ebfe8
This patch optimizes the performance of the is_unbounded_array trait by
dispatching to the new __is_unbounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unbounded_array_v): Use
__is_unbounded_array built-in trait.
Signed-off-by: Ken Matsui
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 19 ++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 36ad9814047..bd57488824b 100644
--- a/libstdc++-v3/include
This patch optimizes the performance of the is_const trait by dispatching to
the new __is_const built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_const): Use __is_const built-in trait.
(is_const_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scalar.
* g++.dg/ext/is_scalar.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc
This patch optimizes the performance of the is_signed trait by dispatching to
the new __is_signed built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_signed): Use __is_signed built-in trait.
(is_signed_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
This patch optimizes the performance of the is_unsigned trait by dispatching
to the new __is_unsigned built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unsigned): Use __is_unsigned built-in
trait.
(is_unsigned_v): Likewise.
Signed-off-by: Ken Matsui
This patch optimizes the performance of the remove_pointer trait by
dispatching to the new remove_pointer built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (remove_pointer): Use __remove_pointer
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include
ype.
(cp_parser_simple_type_specifier): Likewise.
(cp_parser_primary_expression): Call cp_lexer_peek_trait_expr.
Signed-off-by: Ken Matsui
---
gcc/cp/parser.cc | 48 ++--
1 file changed, 30 insertions(+), 18 deletions(-)
diff --git a/gcc/cp/parser
: New file.
Co-authored-by: Patrick Palka
Signed-off-by: Ken Matsui
---
gcc/c-family/c-common.cc | 7 --
gcc/c-family/c-common.h | 5 -
gcc/cp/Make-lang.in | 26
gcc/cp/cp-objcp-common.cc | 8 +-
gcc/cp/cp-trait-head.in | 30 +
gcc/cp/cp-trait.gperf | 74
.
(finish_trait_expr): Likewise.
(finish_trait_type): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Sort built-in traits alphabetically.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 68 -
gcc/cp/cp-trait.def
_GLIBCXX_USE_BUILTIN_TRAIT.
Ken Matsui (40):
c++: Sort built-in traits alphabetically
c-family, c++: Look up built-in traits through gperf
c++: Accept the use of built-in trait identifiers
c++: Implement __is_const built-in trait
libstdc++: Optimize is_const trait performance
c
This patch optimizes the performance of the is_scalar trait by dispatching to
the new __is_scalar built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_scalar): Use __is_scalar built-in
trait.
(is_scalar_v): Likewise.
Signed-off-by: Ken Matsui
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scalar.
* g++.dg/ext/is_scalar.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc
This patch optimizes the performance of the is_signed trait by dispatching to
the new __is_signed built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_signed): Use __is_signed built-in trait.
(is_signed_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_signed.
* g++.dg/ext/is_signed.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc
This patch optimizes the performance of the is_unsigned trait by dispatching
to the new __is_unsigned built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unsigned): Use __is_unsigned built-in
trait.
(is_unsigned_v): Likewise.
Signed-off-by: Ken Matsui
This patch optimizes the performance of the is_compound trait by dispatching
to the new __is_arithmetic built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_compound): Do not use __not_.
(is_compound_v): Use is_fundamental_v instead.
Signed-off-by: Ken Matsui
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_unsigned.
* g++.dg/ext/is_unsigned.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
the original implementation.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 20
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index cc466e0f606..88171e1a672 100644
-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 13 +
1 file changed, 13 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 3acd843f2f2..cc466e0f606 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc++-v3
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_arithmetic.
* g++.dg/ext/is_arithmetic.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
. Optimize its
implementation.
(is_pointer_v): Likewise.
Co-authored-by: Jonathan Wakely
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/bits/cpp_type_traits.h | 8
libstdc++-v3/include/std/type_traits| 44 +
2 files changed, 44 insertions(+), 8
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_pointer.
* g++.dg/ext/is_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3
This patch optimizes the performance of the remove_pointer trait by
dispatching to the new remove_pointer built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (remove_pointer): Use __remove_pointer
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __remove_pointer.
* g++.dg/ext/remove_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h
): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 18 ++
1 file changed, 18 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index bd57488824b..674d398c075 100644
--- a/libstdc++-v3/include/std
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_function.
* g++.dg/ext/is_function.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 19 ++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 36ad9814047..bd57488824b 100644
--- a/libstdc++-v3/include
This patch optimizes the performance of the is_reference trait by dispatching
to the new __is_reference built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_reference): Use __is_reference built-in
trait.
(is_reference_v): Likewise.
Signed-off-by: Ken
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_reference.
* g++.dg/ext/is_reference.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 62 ++-
gcc/cp/semantics.cc
.
(is_member_object_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 17 -
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index e1b10240dc2..792213ebfe8
/is_member_function_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 176 +-
gcc/cp
.
(is_member_function_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 16
1 file changed, 16 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index d7f89cf7c06..e1b10240dc2
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 15 ++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 7fd29d8d9f2..d7f89cf7c06 100644
--- a/libstdc++-v3/include
-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 12
1 file changed, 12 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index d306073a797..7fd29d8d9f2 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc++-v3
CPTK_IS_MEMBER_POINTER.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_member_pointer.
* g++.dg/ext/is_member_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scoped_enum.
* g++.dg/ext/is_scoped_enum.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
This patch optimizes the performance of the is_bounded_array trait by
dispatching to the new __is_bounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_bounded_array_v): Use __is_bounded_array
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc
This patch optimizes the performance of the is_unbounded_array trait by
dispatching to the new __is_unbounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unbounded_array_v): Use
__is_unbounded_array built-in trait.
Signed-off-by: Ken Matsui
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_bounded_array.
* g++.dg/ext/is_bounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
This patch optimizes the performance of the is_array trait by dispatching to
the new __is_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_array): Use __is_array built-in trait.
(is_array_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
(trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_array.
* g++.dg/ext/is_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp
CPTK_IS_UNBOUNDED_ARRAY.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_unbounded_array.
* g++.dg/ext/is_unbounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp
This patch optimizes the performance of the is_const trait by dispatching to
the new __is_const built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_const): Use __is_const built-in trait.
(is_const_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_volatile.
* g++.dg/ext/is_volatile.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3
This patch optimizes the performance of the is_volatile trait by dispatching
to the new __is_volatile built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_volatile): Use __is_volatile built-in
trait.
(is_volatile_v): Likewise.
Signed-off-by: Ken Matsui
: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/Make-lang.in | 2 +-
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf| 1 +
gcc/cp/cp-trait.h| 202
ype.
(cp_parser_simple_type_specifier): Likewise.
(cp_parser_primary_expression): Call cp_lexer_peek_trait_expr.
Signed-off-by: Ken Matsui
---
gcc/cp/parser.cc | 48 ++--
1 file changed, 30 insertions(+), 18 deletions(-)
diff --git a/gcc/cp/parser.cc b/gcc/cp/parser
: New file.
Co-authored-by: Patrick Palka
Signed-off-by: Ken Matsui
---
gcc/c-family/c-common.cc | 7 --
gcc/c-family/c-common.h | 5 -
gcc/cp/Make-lang.in | 26
gcc/cp/cp-objcp-common.cc | 8 +-
gcc/cp/cp-trait-head.in | 30 +
gcc/cp/cp-trait.gperf | 74
.
(finish_trait_expr): Likewise.
(finish_trait_type): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Sort built-in traits alphabetically.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 68 -
gcc/cp/cp-trait.def
by the enum rid change.
Changes in v11:
* Merged all patches into one patch series.
* Rebased on top of trunk.
* Unified commit message style.
* Used _GLIBCXX_USE_BUILTIN_TRAIT.
Ken Matsui (40):
c++: Sort built-in traits alphabetically
c-family, c++: Look up built
: Likewise.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf| 1 +
gcc/cp/cp-trait.h| 211 ++-
gcc/cp/semantics.cc
This patch optimizes the performance of the is_compound trait by dispatching
to the new __is_arithmetic built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_compound): Do not use __not_.
(is_compound_v): Use is_fundamental_v instead.
Signed-off-by: Ken Matsui
This patch optimizes the performance of the is_reference trait by dispatching
to the new __is_reference built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_reference): Use __is_reference built-in
trait.
(is_reference_v): Likewise.
Signed-off-by: Ken
): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 18 ++
1 file changed, 18 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index bd57488824b..674d398c075 100644
--- a/libstdc++-v3/include/std
. Optimize its
implementation.
(is_pointer_v): Likewise.
Co-authored-by: Jonathan Wakely
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/bits/cpp_type_traits.h | 8
libstdc++-v3/include/std/type_traits| 44 +
2 files changed, 44 insertions(+), 8
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_function.
* g++.dg/ext/is_function.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 19 ++-
1 file changed, 18 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 36ad9814047..bd57488824b 100644
--- a/libstdc++-v3/include
: Likewise.
* include/tr1/cmath: Likewise.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc| 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 184
This patch optimizes the performance of the remove_pointer trait by
dispatching to the new remove_pointer built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (remove_pointer): Use __remove_pointer
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include
CPTK_IS_MEMBER_POINTER.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_member_pointer.
* g++.dg/ext/is_member_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp
/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __remove_pointer.
* g++.dg/ext/remove_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h
-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 13 +
1 file changed, 13 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 3acd843f2f2..cc466e0f606 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc++-v3
.
(is_member_object_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 17 -
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index e1b10240dc2..792213ebfe8
This patch optimizes the performance of the is_signed trait by dispatching to
the new __is_signed built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_signed): Use __is_signed built-in trait.
(is_signed_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 12
1 file changed, 12 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index d306073a797..7fd29d8d9f2 100644
--- a/libstdc++-v3/include/std/type_traits
+++ b/libstdc++-v3
the original implementation.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 20
1 file changed, 16 insertions(+), 4 deletions(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index cc466e0f606..88171e1a672 100644
test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 62 ++-
gcc/cp/semantics.cc
.
(is_member_function_pointer_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 16
1 file changed, 16 insertions(+)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index d7f89cf7c06..e1b10240dc2
CPTK_IS_UNBOUNDED_ARRAY.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_unbounded_array.
* g++.dg/ext/is_unbounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_unsigned.
* g++.dg/ext/is_unsigned.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
This patch optimizes the performance of the is_scalar trait by dispatching to
the new __is_scalar built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_scalar): Use __is_scalar built-in
trait.
(is_scalar_v): Likewise.
Signed-off-by: Ken Matsui
(trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_array.
* g++.dg/ext/is_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_bounded_array.
* g++.dg/ext/is_bounded_array.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
.
Signed-off-by: Ken Matsui
---
libstdc++-v3/include/std/type_traits | 15 ++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/libstdc++-v3/include/std/type_traits
b/libstdc++-v3/include/std/type_traits
index 7fd29d8d9f2..d7f89cf7c06 100644
--- a/libstdc++-v3/include
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_reference.
* g++.dg/ext/is_reference.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
This patch optimizes the performance of the is_unsigned trait by dispatching
to the new __is_unsigned built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unsigned): Use __is_unsigned built-in
trait.
(is_unsigned_v): Likewise.
Signed-off-by: Ken Matsui
.
* include/bits/stl_algobase.h: Likewise.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc| 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 155
This patch optimizes the performance of the is_unbounded_array trait by
dispatching to the new __is_unbounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_unbounded_array_v): Use
__is_unbounded_array built-in trait.
Signed-off-by: Ken Matsui
This patch optimizes the performance of the is_array trait by dispatching to
the new __is_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_array): Use __is_array built-in trait.
(is_array_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
/is_member_function_pointer.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp/cp-trait.h | 176 +-
gcc/cp
/bits/stl_algobase.h: Use __is_scalar_type instead.
* include/bits/valarray_array.h: Likewise.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc| 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf | 1 +
gcc/cp
This patch optimizes the performance of the is_bounded_array trait by
dispatching to the new __is_bounded_array built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_bounded_array_v): Use __is_bounded_array
built-in trait.
Signed-off-by: Ken Matsui
---
libstdc
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_scoped_enum.
* g++.dg/ext/is_scoped_enum.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc
.
* semantics.cc (trait_expr_value): Likewise.
(finish_trait_expr): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Test existence of __is_volatile.
* g++.dg/ext/is_volatile.C: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 3
: New test.
Signed-off-by: Ken Matsui
---
gcc/cp/Make-lang.in | 2 +-
gcc/cp/constraint.cc | 3 +
gcc/cp/cp-trait.def | 1 +
gcc/cp/cp-trait.gperf| 1 +
gcc/cp/cp-trait.h| 202
This patch optimizes the performance of the is_volatile trait by dispatching
to the new __is_volatile built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_volatile): Use __is_volatile built-in
trait.
(is_volatile_v): Likewise.
Signed-off-by: Ken Matsui
This patch optimizes the performance of the is_const trait by dispatching to
the new __is_const built-in trait.
libstdc++-v3/ChangeLog:
* include/std/type_traits (is_const): Use __is_const built-in trait.
(is_const_v): Likewise.
Signed-off-by: Ken Matsui
---
libstdc++-v3
and
RID_TRAIT_TYPE empty, which do not have corresponding unique
cannonical spellings.
* cp-trait-head.in: New file.
* cp-trait.gperf: New file.
* cp-trait.h: New file.
Signed-off-by: Ken Matsui
---
gcc/c-family/c-common.cc | 12 +-
gcc/c-family/c
.
(finish_trait_expr): Likewise.
(finish_trait_type): Likewise.
gcc/testsuite/ChangeLog:
* g++.dg/ext/has-builtin-1.C: Sort built-in traits alphabetically.
Signed-off-by: Ken Matsui
---
gcc/cp/constraint.cc | 68 -
gcc/cp/cp-trait.def
in v11:
* Merged all patches into one patch series
* Rebased on top of trunk
* Unified commit message style
* Used _GLIBCXX_USE_BUILTIN_TRAIT
Ken Matsui (39):
c++: Sort built-in traits alphabetically
c-family, c++: Look up built-in traits through gperf
c
601 - 700 of 1220 matches
Mail list logo