PR libstdc++/82644 define TR1 hypergeometric functions in strict modes
commit535975c5919e76bbf6a8fe4bebefa2b80e8b73ac
authorredi <redi@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 3 May 2018 22:58:43 +0000 (3 22:58 +0000)
committerredi <redi@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 3 May 2018 22:58:43 +0000 (3 22:58 +0000)
treee3c52abc2451d4043866f85f82c0270c1e76bf2b
parent984120c942fad71a1fce31be9730df5fd7422e6b
PR libstdc++/82644 define TR1 hypergeometric functions in strict modes

Following a recent change for PR 82644 the non-standard hypergeomtric
functions are not defined by <cmath> when __STRICT_ANSI__ is defined
(e.g. for -std=c++17, or -std=c++14 -D__STDCPP_WANT_MATH_SPEC_FUNCS__).
That caused errors in <tr1/cmath> because the using-declarations for
tr1::hyperg et al are invalid in strict modes.

The solution is to define the TR1 hypergeometric functions inline in
<tr1/cmath> if __STRICT_ANSI__ is defined.

PR libstdc++/82644
* include/tr1/cmath [__STRICT_ANSI__] (hypergf, hypergl, hyperg): Use
inline definitions instead of using-declarations.
[__STRICT_ANSI__] (conf_hypergf, conf_hypergl, conf_hyperg): Likewise.
* testsuite/tr1/5_numerical_facilities/special_functions/
07_conf_hyperg/compile_cxx17.cc: New.
* testsuite/tr1/5_numerical_facilities/special_functions/
17_hyperg/compile_cxx17.cc: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@259912 138bc75d-0d04-0410-961f-82ee72b054a4
libstdc++-v3/ChangeLog
libstdc++-v3/include/tr1/cmath
libstdc++-v3/testsuite/tr1/5_numerical_facilities/special_functions/07_conf_hyperg/compile_cxx17.cc [new file with mode: 0644]
libstdc++-v3/testsuite/tr1/5_numerical_facilities/special_functions/17_hyperg/compile_cxx17.cc [new file with mode: 0644]