[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: C preprocessor
From: |
Ervin Hegedüs |
Subject: |
Re: C preprocessor |
Date: |
Fri, 14 Aug 2020 11:38:22 +0200 |
User-agent: |
NeoMutt/20171215 |
Hi all,
On Fri, Aug 14, 2020 at 11:09:06AM +0200, Hans Åberg wrote:
>
> > On 13 Aug 2020, at 07:49, Giacinto Cifelli <gciofono@gmail.com> wrote:
> >
> > I am wondering if it is possible to interpret a c-preprocessor (the second
> > preprocessor, not the one expanding trigrams and removing "\\\n") or an m4
> > grammar through bison, and in case if it has already been done.
> > I think this kind of tool does not produce a type-2 Chomsky grammar,
> > rather a type-1 or even type-0.
> > Any idea how to build something like an AST from it?
>
> There is a Yaccable C-grammar:
> http://www.quut.com/c/ANSI-C-grammar-y.html
IMHO C macro's are not part of C grammar.
a.
Re: C preprocessor, Hans Åberg, 2020/08/14
- Re: C preprocessor,
Ervin Hegedüs <=