[Bug c++/84612] Overload resolution of operator* fails for valarray<double>
redi at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Feb 28 11:35:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84612
Jonathan Wakely <redi at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
Resolution|--- |INVALID
--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> ---
(v1*=2) doesn't have to deduce anything, it's calling a non-template member
function.
(v1*2) has to deduce the type of the template argument T and it could be
deduced as double or int.
This is not a bug in overload resolution, it's how C++ works.
More information about the Gcc-bugs
mailing list