parser: centralize common auxiliary productions
authorAlvaro Herrera <alvherre@alvh.no-ip.org>
Fri, 22 Jul 2022 10:57:01 +0000 (12:57 +0200)
committerAlvaro Herrera <alvherre@alvh.no-ip.org>
Fri, 22 Jul 2022 11:13:20 +0000 (13:13 +0200)
commit7d158e8cb44b602ab76a3660b9f5f5c5c5992a1f
tree6d5be6e566c9258d173dd80e8504a7bbaf49cbfd
parent9853bf6ab0e3d869d04a3a22959a3c41bf01f0e0
parser: centralize common auxiliary productions

Things like "opt_name" can well be shared by various commands rather
than there being multiple definitions of the same thing.  Rename these
productions and move them to appear together in gram.y, which may
improve chances of reuse in the future.

Discussion: https://postgr.es/m/20220721174212.cmitjpuimx6ssyyj@alvherre.pgsql
src/backend/parser/gram.y