Re: [PATCH] Improve error message for if with an else part while in switch

2023-09-14 Thread Richard Biener via Gcc-patches
On Thu, Sep 14, 2023 at 12:30 AM Andrew Pinski via Gcc-patches wrote: > > While writing some match.pd code, I was trying to figure > out why I was getting an `expected ), got (` error message > while writing an if statement with an else clause. For switch > statements, the if statements cannot

[PATCH] Improve error message for if with an else part while in switch

2023-09-13 Thread Andrew Pinski via Gcc-patches
While writing some match.pd code, I was trying to figure out why I was getting an `expected ), got (` error message while writing an if statement with an else clause. For switch statements, the if statements cannot have an else clause so it would be better to have a decent error message saying