
|
If you were logged in you would be able to see more operations.
|
|
|
|
Issue Links:
|
Duplicate
|
|
This issue duplicates:
|
|
|
STDCXX-512 std::valarray computed assignment operators don't compile with a user-defined class
|
|
|
|
|
|
|
|
| Severity: |
Incorrect Behavior
|
| Resolution Date: |
11/Jan/08 09:50 PM
|
26.3.2.6 p1 says
Each of these operators may only be instantiated for a type T to which the indicated operator can be
applied. Each of these operators performs the indicated operation on each of its elements and the corresponding
element of the argument array. [for operators *=, /=, %=, +=, -=, ^=, &=, |=, <<= and >>=]
The current implementation of the valarray member operators violate these requirements. Internally they use the transform algorithm with one of the function adapters [i.e. multiplies, divides]. So valarray<T>::operator+=() will use T::operator+() and T::operator=() when it should be using T::operator+=(). As a direct result of this, the 26.valarray.cassign test fails to compile on all platforms.
|
|
Description
|
26.3.2.6 p1 says
Each of these operators may only be instantiated for a type T to which the indicated operator can be
applied. Each of these operators performs the indicated operation on each of its elements and the corresponding
element of the argument array. [for operators *=, /=, %=, +=, -=, ^=, &=, |=, <<= and >>=]
The current implementation of the valarray member operators violate these requirements. Internally they use the transform algorithm with one of the function adapters [i.e. multiplies, divides]. So valarray<T>::operator+=() will use T::operator+() and T::operator=() when it should be using T::operator+=(). As a direct result of this, the 26.valarray.cassign test fails to compile on all platforms.
|
Show » |
made changes - 11/Jan/08 09:50 PM
| Field |
Original Value |
New Value |
|
Link
|
|
This issue duplicates STDCXX-512
[ STDCXX-512
]
|
made changes - 11/Jan/08 09:50 PM
|
Resolution
|
|
Duplicate
[ 3
]
|
|
Status
|
Open
[ 1
]
|
Closed
[ 6
]
|
|