multi threaded bison: yyerror (Tamas Sarlos)
28 Jul 2004 12:22:03 -0400

          From comp.compilers

Related articles
multi threaded bison: yyerror (2004-07-28)
Re: multi threaded bison: yyerror (John Millaway) (2004-08-05)
Re: multi threaded bison: yyerror (Laurence Finston) (2004-08-05)
| List of all articles for this month |

From: (Tamas Sarlos)
Newsgroups: comp.compilers
Date: 28 Jul 2004 12:22:03 -0400
Keywords: parse, parallel, question
Posted-Date: 28 Jul 2004 12:22:03 EDT


I'd like to upgrade my flex/bison generated parser to a multi threaded
(pthreads) parser. I know that I have to create a reentrant flex
wrapper and use %pure_parser in bison.

I need to stop parsing (and do some other things) whenever a syntax
error occurs. However yyerror(...) does not have any parameter which
would help to find out in which thread the syntax error occured. I
could use pthread_self() and associate the necessary data with the
thread id, but this solution seems somewhat awkward. Is there a better
way to do it?

Thanks in advance,
      Tamas Sarlos,
      Budapest, Hungary

Post a followup to this message

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