[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

yacc.c does not prototype yyparse in the header

From: Akim Demaille
Subject: yacc.c does not prototype yyparse in the header
Date: Mon, 11 Jun 2012 10:54:51 +0200

Hi all,

Bruce Korb just pointed out to me that Bison 2.5.1 does
not prototype yyparse in the generated header, with yacc.c.
The other skeletons do.  I don't understand why.  I see
nothing in the documentation of Yacc that prevents this,
and surely this is troublesome for many uses.

I don't think there are problems here.  I guess we only have
to pay attention to handle %prefix via M4, and not via CPP,
to avoid having

#define yyparse fooparse

leak from the header (yet we could also #define it first,
then undefine at the end, in case one would like to use the
name "yyparse" in whatever export %code snippet; but do we
really need to cover this?  The less CPP, the better).

Am I missing something?

reply via email to

[Prev in Thread] Current Thread [Next in Thread]