Re: latex grammar (Paolo Bonzini)
3 Apr 2004 09:12:53 -0500

          From comp.compilers

Related articles
latex grammar (Lukasz) (2004-03-26)
Re: latex grammar (Ivan Boldyrev) (2004-04-03)
Re: latex grammar (David Z Maze) (2004-04-03)
Re: latex grammar (2004-04-03)
Re: latex grammar (glen herrmannsfeldt) (2004-04-03)
Re: latex grammar (2004-04-03)
Re: latex grammar (Theodore Norvell) (2004-04-14)
Re: latex grammar (James Leifer) (2004-04-14)
| List of all articles for this month |

From: (Paolo Bonzini)
Newsgroups: comp.compilers,
Date: 3 Apr 2004 09:12:53 -0500
References: 04-03-099
Keywords: parse
Posted-Date: 03 Apr 2004 09:12:53 EST

> Where can I find grammar for latex so I can create parser?
> Thanks for any advices.

LaTeX is interpreted and it is pretty much impossible to create a
complete parser for it. It should be possible (and fairly easy, I'd
say) to support a streamlined version without macros (except very
simple ones -- no \ifs, no \futurelet, no \expandafter, no token
registers, etc.), catcodes (again except possibly some easy ones), and
most of TeX complexities (\hbox/\vbox, \halign, only very simple
glues, \specials, leaders, marks, insertions, etc. etc.). In other
words, expect to hardcode in your parser something to support for
every LaTeX package you care about.


Post a followup to this message

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