[antlr-interest] Parsing C++ source files...

Wigg, J D wiggjd at lsbu.ac.uk
Wed Jul 18 06:34:30 PDT 2007


I have a C++ parser but it parses preprocessed files not source files.
The problem with source files is that they can contain alternatives
controlled by #ifdef/#endif statements and they are not usually
complete and self contained anyway.
 
My version 3.1 is available from the antlr website but if you are
interested in it let me know as I have a 3.2 version nearing
completion which contains a number of corrections. However, AST
production would have to be added.
 
David.
 
Message: 4 from antlr interest digest vol. 32 Isuue 92
Date: Tue, 17 Jul 2007 15:52:03 +0200
From: " Marko Ko?merl " <marko06 at gmail.com>
Subject: [antlr-interest] Parsing C++ source files...
To: antlr-interest at antlr.org
Message-ID:
        <399464b90707170652w1a5f955kf9a341790a53af58 at mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"

Hello!

Maybe there are answers on my question allready on mailing list but I
am
trying to get informations to accomplish what I want too long so I
would be
very grateful and happy if somebody could help me...

I want to parse c++ source file to get AST so that I could make
queries:
- which functions are called in some function
- give me a list of all functions in this (header, cpp) file
- ...

So I would like to write a program that you input a source or header
file or
preprocessed file and you get AST. And then you can make queries...
And I would like to do that in windows and I would be really, really,
really
vary gratefull if somebody could tell me(give me links on tutorial,
tips,...) how to do that and if using ANTLR would be the best or is
there
anything easyer...

Tnx for any kind of answer!

marko
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://www.antlr.org/pipermail/antlr-interest/attachments/2007071
7/1fb96973/attachment-0001.html





--
Copyright in this email and in any attachments belongs to London South Bank University.  This email, and its attachments if any, may be confidential or legally privileged and is intended to be seen only by the person to whom it is addressed.  If you are not the intended recipient, please note the following: (1) You should take immediate action to notify the sender and delete the original email and all copies from your computer systems; (2) You should not read copy or use the contents of the email nor disclose it or its existence to anyone else.

The views expressed herein are those of the author(s) and should not be taken as those of London South Bank University, unless this is specifically stated.

London South Bank University is a company limited by guarantee registered in England and Wales.  The following details apply to London South Bank University: Company number - 00986761; Registered office and trading address - 103 Borough Road London SE1 0AA; VAT number - 778 1116 17; Email address - lsbuinfo at lsbu.ac.uk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.antlr.org/pipermail/antlr-interest/attachments/20070718/cfc80cd3/attachment-0001.html 


More information about the antlr-interest mailing list