On Thu, 13 Oct 2005 16:24:23 -0400, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> BTW, another issue here is that if we did merge the first DECLARE with
> the scope of auto-declared variables, it would be a non backwards
> compatible change. Right now you can do, say,
>
> declare found int;
>
> and it'll override the standard FOUND variable. If we change this then
> you'd get an error. (Of course, it could be argued that that would be
> a Good Thing. But it would inhibit us from adding new auto-declared
> variables that are less central to the language than FOUND, because of
> the risk of breaking existing code.)
Could something be done using alias?
eg
declare x int;
...
declare x alias for outer x
klint.