libstdc++: Fix name clash with _Cosh in QNX headers [PR 95592]
authorJonathan Wakely <jwakely@redhat.com>
Wed, 28 Oct 2020 12:35:44 +0000 (12:35 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Wed, 28 Oct 2020 12:35:44 +0000 (12:35 +0000)
commit72a87d82e0d0741d75c72c8f3d2fc070e3a02b5f
tree0501884eb8c43bc8cc9c784818900d9f364083d3
parent0f7cd5e5735e5536bf7bc8ca2b998f7ce8b4ddee
libstdc++: Fix name clash with _Cosh in QNX headers [PR 95592]

This replaces unqualified names like _Cosh with struct std::_Cosh to
ensure there is no ambiguity with other entities with the same name.

libstdc++-v3/ChangeLog:

PR libstdc++/95592
* include/bits/valarray_after.h (_DEFINE_EXPR_UNARY_OPERATOR)
(_DEFINE_EXPR_BINARY_OPERATOR, _DEFINE_EXPR_BINARY_FUNCTION):
Use elaborated-type-specifier and qualified-id to avoid
ambiguities with QNX system headers.
* testsuite/26_numerics/valarray/95592.cc: New test.
libstdc++-v3/include/bits/valarray_after.h
libstdc++-v3/testsuite/26_numerics/valarray/95592.cc [new file with mode: 0644]