[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bison-1.28a Skeleton file #line suggest

From: Akim Demaille
Subject: Re: Bison-1.28a Skeleton file #line suggest
Date: 05 Oct 2000 11:10:34 +0200
User-agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Channel Islands)

>>>>> "Hans" == Hans Aberg <address@hidden> writes:

Hans> The skeleton file bison.s1 now has lines of the form "#line"
Hans> only -- perhaps the idea is that the rest of the "#line"
Hans> directive should be supplied by "make".

Right, see the conversion from bison.s1 to bison.simple in

bison.simple: bison.s1 Makefile
        sed -e "s/@bison_version@/$(VERSION)/" $(srcdir)/bison.s1 | \
        awk '\
        /^#line/ { printf "#line %d \"$(datadir)/bison.simple\"\n", NR+1; next 
        { print }' >address@hidden
        mv address@hidden $@

Hans> It strikes me though that it would be better to allow one having
Hans> lines with %line in the skeleton file, and Bison then supplies
Hans> the complete #line <line-number> "<file-name>"

Hm.  I don't know.  I mean, it's a good idea and patches are always
welcome.  But I think it is a good thing that the skeleton be signed
with the version of the distribution it's coming from (in order to be
able to check that there is no mismatch between bison(1) and

But maybe I'm too paranoid.

Hans> -- The thing is, that with this construct, it is easier to treat
Hans> the skeleton file as just another source file; one can edit it
Hans> after the Bison sources have been compiled. (And not so
Hans> difficult to implement either.)

I agree.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]