bug-bison
[Top][All Lists]
Advanced

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

RE: "parser stack overflow" in bison-1.35, bad "#if" in bison.sim ple


From: Hans Aberg
Subject: RE: "parser stack overflow" in bison-1.35, bad "#if" in bison.sim ple
Date: Sun, 25 Aug 2002 16:18:05 +0200

At 15:50 +0200 2002/08/25, Miko Nahum wrote:
>I knew that 1.28 is old. However, 1.35 is the last one
>from GNU site (http://ftp.gnu.org/) whereas 1.49x is at alpha
>stage (not even beta). So what version IS supported ?

I think only the latest beta (I'm not a Bison developer).

>OK, C stack enlargement does not invoke the C++ copy constructors as it
>should it, but look at the condition in "bison.simple":
>
>#if (! defined (yyoverflow) \
>     && (! defined (__cplusplus) \
>         || (YYLTYPE_IS_TRIVIAL && YYSTYPE_IS_TRIVIAL)))
>
>That is, you have either:
>       NOT C++ or (YYLTYPE and YYSTYPE)

That's just some experimental stuff. Earliser verson were never correct
with C++, only compilable.

>So if someone is using the "%union" and location, it will cause the C stack
>enralgement to be used - EVEN WHEN COMPILED WITH C++ compiler, right ?? So
>in such case C++ copy constructors does NOT invoked. What than ??

Unions cannot be used under C++ with types that have nontrival constructors.

>For the meantime, till I shift to 1.49++ I'll have to workaround it as I
>did.

It's not 1.49++, just 1.49x with C/C++ support, depending on which skeleton
file you choose.

  Hans Aberg






reply via email to

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