commit b2e2403705ee71f141db8b9a4bac947ce3116f1d
Author: Roberto E. Vargas Caballero <[email protected]>
AuthorDate: Mon Aug 1 16:05:01 2016 +0200
Commit: Roberto E. Vargas Caballero <[email protected]>
CommitDate: Mon Aug 1 16:05:01 2016 +0200
[cc1] Avoid recovery in elseclause
We do not want to recover in any cpp function, because we are out
of synchronization at that moment.
diff --git a/cc1/cpp.c b/cc1/cpp.c
index 53daa3c..80131f7 100644
--- a/cc1/cpp.c
+++ b/cc1/cpp.c
@@ -652,8 +652,10 @@ elseclause(void)
{
int status;
- if (cppctx == 0)
- error("#else without #ifdef/ifndef");
+ if (cppctx == 0) {
+ cpperror("#else without #ifdef/ifndef");
+ return;
+ }
status = (ifstatus[cppctx-1] ^= 1);
cppoff += (status) ? -1 : 1;