This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/49812] strange return type for built-in operator++(int, int)
- From: "jason at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 5 Aug 2011 14:42:17 +0000
- Subject: [Bug c++/49812] strange return type for built-in operator++(int, int)
- Auto-submitted: auto-generated
- References: <bug-49812-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49812
--- Comment #2 from Jason Merrill <jason at gcc dot gnu.org> 2011-08-05 14:42:00 UTC ---
operator++ isn't returning void. The problem is that GCC is treating it as a
volatile prvalue, which can't bind to either const volatile int& or const int&.
But int prvalues shouldn't have cv-quals.