RE: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Dalbey, Keith via Gcc
-Original Message- From: Andrew Pinski Sent: Friday, July 12, 2024 1:20 PM To: Dalbey, Keith Cc: Jonathan Wakely ; gcc@gcc.gnu.org Subject: Re: [EXTERNAL] Re: g++12 broke my system of overloaded operator<< On Fri, Jul 12, 2024 at 12:10 PM Dalbey, Keith via Gcc wrote: > >

Re: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Jonathan Wakely via Gcc
On Fri, 12 Jul 2024 at 20:08, Dalbey, Keith wrote: > > The means by which this FIX was implemented caused OTHER problems > > template > std::ostream& operator<<(std::ostream& os, const std::pair& pr) > { > os << "(" << pr.first << ", " << pr.second << ")"; > return os; > } > > Wil

Re: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Andrew Pinski via Gcc
eed to forward declare some of the contents of the .cpp > file ahead of including this header file) > > But really a header file that can't be included in other header files and can > only be included as the absolute last header file in a .cpp file is a > unreasonable set of hoops

Re: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Jonathan Wakely via Gcc
On Fri, 12 Jul 2024 at 20:08, Dalbey, Keith wrote: > > The means by which this FIX was implemented caused OTHER problems > > template > std::ostream& operator<<(std::ostream& os, const std::pair& pr) > { > os << "(" << pr.first << ", " << pr.second << ")"; > return os; > } > > Wil

Re: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Jonathan Wakely via Gcc
On Fri, 12 Jul 2024 at 17:58, Dalbey, Keith via Gcc wrote: > > I'm not going to argue about the change for CONCRETE operators, I'm going to > argue about the loss of power/flexibility for TEMPLATED operators, because it > defeats the whole purpose of TEMPLATED functions/operators otherwise This

RE: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Dalbey, Keith via Gcc
But really a header file that can't be included in other header files and can only be included as the absolute last header file in a .cpp file is a unreasonable set of hoops to jump through to get TEMPLATED operator<< 's to work, which should just work BECAUSE THEY'RE TEMP

RE: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Dalbey, Keith via Gcc
albey, Keith Sent: Friday, July 12, 2024 10:58 AM To: Andrew Pinski Cc: gcc@gcc.gnu.org Subject: RE: [EXTERNAL] Re: g++12 broke my system of overloaded operator<< I'm not going to argue about the change for CONCRETE operators, I'm going to argue about the loss of power/flexibility fo

RE: [EXTERNAL] Re: g++12 broke my system of overloaded operator<

2024-07-12 Thread Dalbey, Keith via Gcc
operator<<'s SHOULD still just work without undoing your fix for CONCRETE operators Not sure how the compiler would know whether the current file was the FIRST file or not, but it seems like the same problem that had to be solved for class declarations/definitions when there are method