🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: net.lang.c
Article #9691

Re: Null source transformer for C

#9691
From: Jon Leech
Date: Sat, 01 Nov 1986 01:37
21 lines
1485 bytes
In article <5058@brl-smoke.ARPA> jrv@MITRE-BEDFORD.ARPA (James R. Van Zandt) writes:
>Several times I've wanted to make a change to some C source code that
>would be minor, but requires parsing it.  Some examples are:
>
>       Remove all the comments.
>
>       Add a diagnostic printout at the beginning of each function.
>

>       replace the operators + - * / with equivalent function calls.
	
	Another example that I badly needed recently is a 'diff'-like program
driven by syntax rather than text; I had two divergent versions of a large
program with differing indentations, preprocessor usage, etc. The idea is
to build parse trees for two sets of source code and compare them function
by function at the syntax level, then reconstruct source code for the 


    -- Jon Leech (jon@csvax.caltech.edu || ...seismo!cit-vax!jon)
    Caltech Computer Science Graphics Group
    __@/
Technical Details
Message-ID: <1105@cit-vax.Caltech.Edu>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!seismo!lll-crg!nike!cit-vax!oddhack!jon
References: <5058@brl-smoke.ARPA>

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!mnetor!seismo!lll-crg!nike!cit-vax!oddhack!jon
From: jon@oddhack.Caltech.Edu (Jon Leech)
Newsgroups: net.lang.c
Subject: Re: Null source transformer for C
Message-ID: <1105@cit-vax.Caltech.Edu>
Date: Fri, 31-Oct-86 20:37:28 EST
Article-I.D.: cit-vax.1105
Posted: Fri Oct 31 20:37:28 1986
Date-Received: Mon, 3-Nov-86 19:27:07 EST
References: <5058@brl-smoke.ARPA>
Sender: news@cit-vax.Caltech.Edu
Reply-To: jon@cit-vax.UUCP (Jon Leech)
Organization: California Institute of Technology
Lines: 21