re: Help - partial parsing of C

ohl@crunch.ikp.physik.th-darmstadt.de (Thorsten Ohl)
Thu, 23 Jan 92 20:58:07 -2300

          From comp.compilers

Related articles
re: Help - partial parsing of C ohl@crunch.ikp.physik.th-darmstadt.de (1992-01-23)
Re: Help - partial parsing of C al@nmt.edu (1992-01-24)
| List of all articles for this month |
Newsgroups: comp.compilers
From: ohl@crunch.ikp.physik.th-darmstadt.de (Thorsten Ohl)
Keywords: C, parse
Organization: Compilers Central
Date: Thu, 23 Jan 92 20:58:07 -2300

> On Mon, 20 Jan 92 15:47:32 GMT, Daniel Tallis <dta@dcs.exeter.ac.uk> said:
> As part of my third year project I need to do partial parsing of C
> programs. By partial parsing, I mean all I need to do is delimit each
> individual statement and determine its type
> [...]
> The reason for wanting to do this is that the project is a 'smart editor'
> which 'understands' the program to a certain extent.


`Partial' will have another meaning in this context: since the program is
most probably not a valid C program while you're editing it,
Bison/byacc/yacc might have a hard time parsing it. A somewhat
unorthodox, but very interesting solution for a similar problem can be
found in D. E. Knuth's Web system. The C version (written by Silvio Levy
and DEK) can be ftp'd from labrea.stanford.edu:/pub/cweb/. But beware:
version 2.0 doesn't recognize ANSI C prototypes yet.


Hope this helps,
Thorsten


-=
Thorsten Ohl, DESY (-T-), Notkestr. 85, W-2000 Hamburg 52, FRG
phone: +49-40-8998-3699, fax: +49-40-8998-3282
e-mail: <t00ohl@dhhdesy3.bitnet>, <ohl@gnu.ai.mit.edu>,
                <ohl@crunch.ikp.physik.th-darmstadt.de>
--


Post a followup to this message

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