mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-09 00:47:41 +08:00
Remove plpgsql's separate lexer (finally!), in favor of using the core lexer
directly. This was a lot of trouble, but should be worth it in terms of not having to keep the plpgsql lexer in step with core anymore. In addition the handling of keywords is significantly better-structured, allowing us to de-reserve a number of words that plpgsql formerly treated as reserved.
This commit is contained in:
@ -3189,3 +3189,18 @@ $$ language plpgsql;
|
||||
select * from conflict_test();
|
||||
|
||||
drop function conflict_test();
|
||||
|
||||
-- Check that an unreserved keyword can be used as a variable name
|
||||
|
||||
create function unreserved_test() returns int as $$
|
||||
declare
|
||||
forward int := 21;
|
||||
begin
|
||||
forward := forward * 2;
|
||||
return forward;
|
||||
end
|
||||
$$ language plpgsql;
|
||||
|
||||
select unreserved_test();
|
||||
|
||||
drop function unreserved_test();
|
||||
|
||||
Reference in New Issue
Block a user