This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug libstdc++/43785] [4.5/4.6 Regression] very basic regression in std::make_pair
- From: "redi at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 19 Apr 2010 15:37:14 -0000
- Subject: [Bug libstdc++/43785] [4.5/4.6 Regression] very basic regression in std::make_pair
- References: <bug-43785-17658@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #14 from redi at gcc dot gnu dot org 2010-04-19 15:37 -------
(In reply to comment #13)
> Well it's about time someone put a stop to it ;-)
Seriously though, it's quicker to write e.g.
return std::pair<uint32_t, uint32_t>(x, y)
than
return std::make_pair<uint32_t, uint32_t>(x, y);
I can't see why anyone would use the latter if they know both the arguments in
advance. There is a valid use case for make_pair<uint32_t>(x, y), which
suppresses deduction for the first argument but not the second.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43785