mirror of git://gcc.gnu.org/git/gcc.git
complex (complex<float>::real, [...]): Declare as const member functions.
2013-04-22 Paolo Carlini <paolo.carlini@oracle.com> N3669 * include/std/complex (complex<float>::real, complex<float>::imag, complex<double>::real, complex<double>::imag, complex<long double>::real, complex<long double>::imag): Declare as const member functions. * include/std/type_traits (integral_constant<>::operator value_type): Likewise. From-SVN: r198141
This commit is contained in:
parent
88a581daa7
commit
9191d7a84a
|
|
@ -1,3 +1,13 @@
|
||||||
|
2013-04-22 Paolo Carlini <paolo.carlini@oracle.com>
|
||||||
|
|
||||||
|
N3669
|
||||||
|
* include/std/complex (complex<float>::real, complex<float>::imag,
|
||||||
|
complex<double>::real, complex<double>::imag,
|
||||||
|
complex<long double>::real, complex<long double>::imag): Declare
|
||||||
|
as const member functions.
|
||||||
|
* include/std/type_traits (integral_constant<>::operator value_type):
|
||||||
|
Likewise.
|
||||||
|
|
||||||
2013-04-22 Paolo Carlini <paolo.carlini@oracle.com>
|
2013-04-22 Paolo Carlini <paolo.carlini@oracle.com>
|
||||||
|
|
||||||
PR libstdc++/57010
|
PR libstdc++/57010
|
||||||
|
|
|
||||||
|
|
@ -1066,11 +1066,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||||
// DR 387. std::complex over-encapsulated.
|
// DR 387. std::complex over-encapsulated.
|
||||||
__attribute ((__abi_tag__ ("cxx11")))
|
__attribute ((__abi_tag__ ("cxx11")))
|
||||||
constexpr float
|
constexpr float
|
||||||
real() { return __real__ _M_value; }
|
real() const { return __real__ _M_value; }
|
||||||
|
|
||||||
__attribute ((__abi_tag__ ("cxx11")))
|
__attribute ((__abi_tag__ ("cxx11")))
|
||||||
constexpr float
|
constexpr float
|
||||||
imag() { return __imag__ _M_value; }
|
imag() const { return __imag__ _M_value; }
|
||||||
#else
|
#else
|
||||||
float&
|
float&
|
||||||
real() { return __real__ _M_value; }
|
real() { return __real__ _M_value; }
|
||||||
|
|
@ -1217,11 +1217,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||||
// DR 387. std::complex over-encapsulated.
|
// DR 387. std::complex over-encapsulated.
|
||||||
__attribute ((__abi_tag__ ("cxx11")))
|
__attribute ((__abi_tag__ ("cxx11")))
|
||||||
constexpr double
|
constexpr double
|
||||||
real() { return __real__ _M_value; }
|
real() const { return __real__ _M_value; }
|
||||||
|
|
||||||
__attribute ((__abi_tag__ ("cxx11")))
|
__attribute ((__abi_tag__ ("cxx11")))
|
||||||
constexpr double
|
constexpr double
|
||||||
imag() { return __imag__ _M_value; }
|
imag() const { return __imag__ _M_value; }
|
||||||
#else
|
#else
|
||||||
double&
|
double&
|
||||||
real() { return __real__ _M_value; }
|
real() { return __real__ _M_value; }
|
||||||
|
|
@ -1369,11 +1369,11 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||||
// DR 387. std::complex over-encapsulated.
|
// DR 387. std::complex over-encapsulated.
|
||||||
__attribute ((__abi_tag__ ("cxx11")))
|
__attribute ((__abi_tag__ ("cxx11")))
|
||||||
constexpr long double
|
constexpr long double
|
||||||
real() { return __real__ _M_value; }
|
real() const { return __real__ _M_value; }
|
||||||
|
|
||||||
__attribute ((__abi_tag__ ("cxx11")))
|
__attribute ((__abi_tag__ ("cxx11")))
|
||||||
constexpr long double
|
constexpr long double
|
||||||
imag() { return __imag__ _M_value; }
|
imag() const { return __imag__ _M_value; }
|
||||||
#else
|
#else
|
||||||
long double&
|
long double&
|
||||||
real() { return __real__ _M_value; }
|
real() { return __real__ _M_value; }
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
|
||||||
static constexpr _Tp value = __v;
|
static constexpr _Tp value = __v;
|
||||||
typedef _Tp value_type;
|
typedef _Tp value_type;
|
||||||
typedef integral_constant<_Tp, __v> type;
|
typedef integral_constant<_Tp, __v> type;
|
||||||
constexpr operator value_type() { return value; }
|
constexpr operator value_type() const { return value; }
|
||||||
};
|
};
|
||||||
|
|
||||||
template<typename _Tp, _Tp __v>
|
template<typename _Tp, _Tp __v>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue