From 04a3b0a0927d8a065c01972646ef724ec8e8433e Mon Sep 17 00:00:00 2001 From: ceriel Date: Wed, 1 Mar 1989 13:39:50 +0000 Subject: [PATCH] avoid spurious error messages about missing #endif --- util/cpp/domacro.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/util/cpp/domacro.c b/util/cpp/domacro.c index d9db2b2d..c7e20344 100644 --- a/util/cpp/domacro.c +++ b/util/cpp/domacro.c @@ -365,8 +365,9 @@ do_endif() { PushBack(); skipline(); - if (nestlevel-- <= svnestlevel[nestcount]) + if (nestlevel <= svnestlevel[nestcount]) error("#endif without corresponding #if"); + else nestlevel--; } PRIVATE