Re: PostgreSQL 7.4.2 on SunOS 4.1.4 - Mailing list pgsql-admin

From Tom Lane
Subject Re: PostgreSQL 7.4.2 on SunOS 4.1.4
Date
Msg-id 21008.1086792489@sss.pgh.pa.us
Whole thread Raw
In response to PostgreSQL 7.4.2 on SunOS 4.1.4  ("Cook, Tom" <Tom.Cook@subcorp.com.au>)
List pgsql-admin
"Cook, Tom" <Tom.Cook@subcorp.com.au> writes:
> ERROR:  syntax error at line 3467: unexpected token "syntax error"

> This line number seems to be from postgres.bki, and it appears to be
> one short of where the error actually arises - inserting a blank line
> at line 3468 moves the error to line 3468.

Hmm, both the weird phrasing of the error message and the off-by-one
line count are pretty obvious bugs now that I look at bootscanner.l.
I guess nobody noticed because so few people have ever seen an actual
syntax error here.

> The first 'declare unique index' line is the one that is causing the
> problem - commenting it out just moves the same error message to the
> next line.

It looks fine to me too.  I think that either the bootstrap lexer
or parser must be broken on your machine.

> I have not regenerated the bison-generated parser source file - it is
> the one that comes with PostgreSQL 7.4.2.

Are you speaking specifically of

src/backend/bootstrap/bootparse.c
src/backend/bootstrap/bootscanner.c
src/backend/bootstrap/bootstrap_tokens.h

Make doubly sure that these didn't get regenerated.  If they didn't, the
only other theory that comes to mind is a compiler bug.  Which compiler
are you using exactly?

            regards, tom lane

pgsql-admin by date:

Previous
From: "David F. Skoll"
Date:
Subject: Dump only part of a DB
Next
From: "Scott Marlowe"
Date:
Subject: Re: PostgreSQL Performance