Skip site navigation (1) Skip section navigation (2)

Re: Compilation errors

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Gregory Stark <stark(at)enterprisedb(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Compilation errors
Date: 2007-03-01 00:27:48
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Tom Lane wrote:
> Andrew Dunstan <andrew(at)dunslane(dot)net> writes:
>> Actually, we couldn't.The definition section from the .l file gets 
>> included after these functions. So we'd need to include something in 
>> gram.y before including scan.c.
> Actually, since we don't use any of those functions, the following
> advice from the 2.5.33 flex manual seems useful:
>    A number of options are available for lint purists who want to
> suppress the appearance of unneeded routines in the generated scanner.
> Each of the following, if unset (e.g., `%option nounput'), results in
> the corresponding routine not appearing in the generated scanner:
>          input, unput
>          yy_push_state, yy_pop_state, yy_top_state
>          yy_scan_buffer, yy_scan_bytes, yy_scan_string
>          yyget_extra, yyset_extra, yyget_leng, yyget_text,
>          yyget_lineno, yyset_lineno, yyget_in, yyset_in,
>          yyget_out, yyset_out, yyget_lval, yyset_lval,
>          yyget_lloc, yyset_lloc, yyget_debug, yyset_debug
>    (though `yy_push_state()' and friends won't appear anyway unless you
> use `%option stack)'.
> However, I'm not sure whether 2.5.4 will choke on unrecognized %option
> commands --- if it has to be conditional on version it'll be a PITA.

%option noyyget_in

causes flex 2.5.4a to barf:

/usr/bin/flex -CF -o'scan.c' scan.l
"scan.l", line 106: unrecognized %option: yyget
make[3]: *** [scan.c] Error 1


In response to


pgsql-hackers by date

Next:From: Jonah H. HarrisDate: 2007-03-01 00:40:56
Subject: Re: COMMIT NOWAIT Performance Option
Previous:From: Joshua D. DrakeDate: 2007-03-01 00:26:30
Subject: Re: [HACKERS]

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group