Re: Lex,Yacc for ThreadSafe Applications?

"Kamal R. Prasad" <kamalp@ix.netcom.com>
31 Jul 2000 23:51:51 -0400

          From comp.compilers

Related articles
Lex,Yacc for ThreadSafe Applications? qing@plx.com (2000-07-18)
Re: Lex,Yacc for ThreadSafe Applications? kamalp@ix.netcom.com (Kamal R. Prasad) (2000-07-31)
Re: Lex,Yacc for ThreadSafe Applications? hannah@mamba.pond.sub.org (2000-08-04)
| List of all articles for this month |
From: "Kamal R. Prasad" <kamalp@ix.netcom.com>
Newsgroups: comp.compilers
Date: 31 Jul 2000 23:51:51 -0400
Organization: MindSpring Enterprises
References: 00-07-019
Keywords: lex, yacc, comment

you may want to try bison and flex which are modified versions of yacc and
lex.
also available (though I haven't used them) are bison++ and flex++.
bison has a mechanism wherein you could specify a prefix so that you
create AAparse(), BBparse() etc.. instead of the std yyparse().
the global variables are also changed accordingly.you can call each of
these instances in each of the threads.this way, more than 1 thread can
call each of the parse() functions at the same time. ditto for flex.
if you use the C++ version, that would give you the flexibility to create
more than 1 instance dynamically.
-kamal
[Flex C++ scanners should be OK for threads. Haven't seen a thread-safe
yacc. -John]


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.