Re: BUG #6165: documentation bug in plpgsql-declarations.html and plpgsql-statements.html (or plpgsql parser bug)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: raf <raf(at)raf(dot)org>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #6165: documentation bug in plpgsql-declarations.html and plpgsql-statements.html (or plpgsql parser bug)
Date: 2011-08-22 20:17:04
Message-ID: 9622.1314044224@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> On Wed, Aug 17, 2011 at 1:21 AM, raf <raf(at)raf(dot)org> wrote:
>> so, there is either a plpgsql parser bug that treats the sql equality
>> operator as the plpgsql assignment operator, or "=" is an undocumented
>> alternative to the documented plpgsql assignment operator (":=").

> I think it's the latter.

It's definitely intentional, not a bug, so far as the source code is
concerned:

assign_operator : '='
| COLON_EQUALS
;

> I have a vague recollection that we might
> have left that undocumented on purpose, but I'm not actually sure why
> we support it in the first place.

I think it's legacy at this point. We have discussed before whether to
document it, and IIRC the general feeling was "if we do document it,
we'll never be able to get rid of it". Whether we could get rid of it
now (instead of documenting it) was not seriously discussed. I've seen
at least a few people saying that they do rely on it ...

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Eduard Rozenberg 2011-08-25 00:59:28 BUG #6175: Service name should be fixed
Previous Message Peter Eisentraut 2011-08-22 16:37:43 Re: BUG #5963: make -j4 check fails