Re: New warnings in plgsql/src/scan.l

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Alvaro Herrera <alvherre(at)surnet(dot)cl>, Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: New warnings in plgsql/src/scan.l
Date: 2005-07-05 16:02:15
Message-ID: 23428.1120579335@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Alvaro Herrera wrote:
>> I see new warnings in the generation of plpgsql's scanner:
>>
>> /usr/bin/flex -Pplpgsql_base_yy
>> -o'/pg/source/00orig/src/pl/plpgsql/src/pl_scan.c'
>> /pg/source/00orig/src/pl/plpgsql/src/scan.l
>> /pg/source/00orig/src/pl/plpgsql/src/scan.l:198: warning, the
>> character range [-] is ambiguous in a case-insensitive scanner

> This warning has existed in one from or another ever since the latest
> flex version is in use. For example, 7.4 shows it as well. I don't
> think we have to do anything (except rewrite PL/pgSQL's parser, which
> is somehow planned (or hoped for) anyway).

The warnings are pointing at uses of "identifier" and similar. I think
it's probably unhappy that we are writing things like

ident_start [A-Za-z\200-\377_]

along with '%option case-insensitive'. However this doesn't strike me
as ambiguous, merely redundant ...

It may also be important to invoke flex in C locale --- I seem to recall
some previous discussion to the effect that its idea of "case
insensitive" depends on the build-time locale.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Marko Kreen 2005-07-05 16:21:17 Re: pgcrypto 3des failure, OpenSSL 0.9.8, Solaris 9/sparc
Previous Message Tom Lane 2005-07-05 15:54:47 Re: [PATCHES] Disable page writes when fsync off, add GUC