🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.misc.discuss
Article #2228

Re: YACC with C++

#2228
From: Paul D. Smith
Date: Thu, 15 Feb 1996 00:00
26 lines
2030 bytes
%% Regarding YACC with C++;
%% sirichot@centaur.sps.mot.com (Supamas Sirichotiyakul) writes:

    ss> Does anyone know where to find yacc or something similar that
    ss> can create a c++ parser class?

I would forget LEX and YACC altogether and go with a more capable parser
generator.  My advice is to use PCCTS, which has an excellent C++
interface as well as C.  Defining grammars in PCCTS is basically similar
to YACC: both use BNF format.  PCCTS uses enhanced BNF, which is much
nicer to write grammars for.  Also, PCCTS can generate N-token lookahead
parsers, whereas YACC is limited to 1 token lookahead.

All in all, a much nicer tool.  Check out one or more of:

  news:comp.compilers.tools.pccts
  http://www.igs.net/~mtr/software-development/pccts.htm
  http://www.mcs.net/~tmoog/pccts.html
-- 
-------------------------------------------------------------------------------
 Paul D. Smith <psmith@baynetworks.com>         Network Management Development
 Senior Software Engineer                                   Bay Networks, Inc.
-----------------------------------------------==<http://www.baynetworks.com/>-
 "Please remain calm...I may be mad, but I am a professional." --Mad Scientist
-------------------------------------------------------------------------------
     These are my opinions--Bay Networks takes no responsibility for them.
Technical Details
Message-ID: <p5spgcl32f.fsf@lemming.wellfleet.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <4fvuos$cke@newsgate.sps.mot.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10ba33,eec0c9cb243afc92
X-Google-Attributes: gid10ba33,public
X-Google-Thread: 1025b4,eec0c9cb243afc92
X-Google-Attributes: gid1025b4,public
From: psmith@lemming.wellfleet.com (Paul D. Smith)
Subject: Re: YACC with C++
Date: 1996/02/15
Message-ID: <p5spgcl32f.fsf@lemming.wellfleet.com>
X-Deja-AN: 139528484
sender: psmith@lemming.wellfleet.com
references: <4fvuos$cke@newsgate.sps.mot.com>
to: sirichot@centaur.sps.mot.com (Supamas Sirichotiyakul)
organization: Bay Networks, Inc., Billerica, MA
reply-to: psmith@wellfleet.com
newsgroups: gnu.misc.discuss,gnu.g++.help