help-bison
[Top][All Lists]
Advanced

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

Re: specifying a C++ template class parse-param


From: Geoff Alexander
Subject: Re: specifying a C++ template class parse-param
Date: Mon, 18 Dec 2006 22:31:23 -0500

On 14 Dec 2006, at 4:54, Hans Aberg wrote:
> On 14 Dec 2006, at 07:20, address@hidden wrote:
>
> > I'm using Bison to generate a parser that I compile with g++.  I'm  
> > using
> > using the default Bison skeleton, not the Bison C++ skeleton.
>
> Cmopiling the C parser as C++ jas been dropped. See the recent thread  
> "Bison and C++" for some reasons.

Thanks for the pointer.  I'll look at using the C++ skeleton.

> > Before making the update to my awk script, I thought I'd ask if anyone
> > has a better idea on how to handle a C++ template class parse- 
> > param.  In
> > particular, it would be great if there was a way to have Bison
> > automatically make functions taking parse-parm parameters template
> > functions on T, so I wouldn't need to modify Bison generated code.  
> > Would
> > using Bison's C++ skeleton help?
>
> It is an interesting question, but why do you need it, that is, what  
> is the template class used for in the parser?

The parser extracts elements from an input file and stores them in an
ordered collection passed to the parser.  The order ordered collection is
based on std::set with the template class used to specify the ordering of
the ordered collection.

Geoff Alexander






reply via email to

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