Re: bison-3.0.5 released [stable]

2018-06-17 Thread Akim Demaille
> Le 2 juin 2018 à 19:08, Hans Åberg a écrit : > > >> On 28 May 2018, at 07:33, Akim Demaille wrote: >> >> We are happy to announce the release of GNU Bison 3.0.5, a bug fix >> release. > > There is a bug in 'make install-pdf', because in the directories po/ and > runtime-po/, the

Re: Bison C++ mid-rule value lost with variants

2018-06-17 Thread Hans Åberg
> On 17 Jun 2018, at 16:02, Akim Demaille wrote: > Or go for a lighter syntax... Indeed. > expr: > NUM > | expr { $$ = 42; } '+' NUM { std::cout << $2 << '\n'; }; > Personally, I prefer the prefix forms, but they don’t blend > nicely with named references: > > expr: > NUM > | expr { $$ =

Re: Bison C++ mid-rule value lost with variants

2018-06-17 Thread Rici Lake
I enthusiastically support this proposal. I agree with the preference for prefix positioning. The `%type` keyword is just noise, imho, and thus unnecessary. I like the `name={ code }` syntax, too, but it's probably too late for that. Perhaps `{ code }[name]` would be a plausible alternative

Re: Bison C++ mid-rule value lost with variants

2018-06-17 Thread Akim Demaille
Hi all, > Le 29 juin 2017 à 15:55, Piotr Marcińczyk a écrit : > > I supposedly found a bug in lalr1.cc skeleton with variant semantic type. > When using mid-rule action { $$ = value; } to return a value that > will be used in further semantic actions, it appears that the value on > stack