P08184R0: Generalizing the Range-Based For Loop
authorCasey Carter <casey@carter.net>
Mon, 14 Mar 2016 19:57:54 +0000 (19:57 +0000)
committerJason Merrill <jason@gcc.gnu.org>
Mon, 14 Mar 2016 19:57:54 +0000 (15:57 -0400)
commit598a208cc0442bf7109ee545fa82d6c0607b9adf
tree34ab5c82e313155f42a5d0b7684c3fda07a35970
parent3cbf012a4007511b8989d90e9450a93d4c75a8a6
P08184R0: Generalizing the Range-Based For Loop

* parser.c (cp_convert_range_for): Set the type of __end separately.
(cp_parser_perform_range_for_lookup): Allow different begin/end
types if they are comparable.

Co-Authored-By: Jason Merrill <jason@redhat.com>
From-SVN: r234191
gcc/cp/ChangeLog
gcc/cp/parser.c
gcc/testsuite/g++.dg/cpp0x/range-for5.C
gcc/testsuite/g++.dg/cpp1z/range-for1.C [new file with mode: 0644]