@@ -6993,17 +6993,23 @@ index_tablespace_clause
69936993 * ------------------------------------------------------------------------------------ *
69946994 */
69956995data_type
6996- = & postgres head :named_data_type tail :(__ array_bounds )+ {
6997- return loc (createArrayDataTypeChain (head, tail));
6996+ = setof_data_type
6997+
6998+ setof_data_type
6999+ = & postgres kw :(SETOF __ ) dataType :array_data_type {
7000+ return loc ({ type: " setof_data_type" , setofKw: read (kw), dataType })
69987001 }
6999- / & postgres dataType :named_data_type tz :(__ (WITHOUT / WITH ) __ TIME __ ZONE ) {
7000- return loc ({
7001- type: " with_time_zone_data_type" ,
7002- dataType,
7003- withTimeZoneKw: read (tz),
7004- });
7002+ / array_data_type
7003+
7004+ array_data_type
7005+ = & postgres head :with_time_zone_data_type tail :(__ array_bounds )* {
7006+ if (tail .length > 0 ) {
7007+ return loc (createArrayDataTypeChain (head, tail));
7008+ } else {
7009+ return head;
7010+ }
70057011 }
7006- / named_data_type
7012+ / ! postgres with_time_zone_data_type
70077013
70087014array_bounds
70097015 = "[" bounds :(__ empty __ ) "]" {
@@ -7013,6 +7019,16 @@ array_bounds
70137019 return loc ({ type: " array_bounds" , bounds: read (bounds) });
70147020 }
70157021
7022+ with_time_zone_data_type
7023+ = & postgres dataType :named_data_type tz :(__ (WITHOUT / WITH ) __ TIME __ ZONE ) {
7024+ return loc ({
7025+ type: " with_time_zone_data_type" ,
7026+ dataType,
7027+ withTimeZoneKw: read (tz),
7028+ });
7029+ }
7030+ / named_data_type
7031+
70167032named_data_type
70177033 = kw :(type_name __ ) params :paren$list$literal {
70187034 return loc ({ type: " named_data_type" , name: read (kw), params });
@@ -9782,6 +9798,7 @@ SERVER = kw:"SERVER"i !ident_part { return loc(createK
97829798SESSION = kw :"SESSION" i ! ident_part { return loc (createKeyword (kw)); }
97839799SESSION_USER = kw :"SESSION_USER" i ! ident_part { return loc (createKeyword (kw)); }
97849800SET = kw :"SET" i ! ident_part { return loc (createKeyword (kw)); }
9801+ SETOF = kw :"SETOF" i ! ident_part { return loc (createKeyword (kw)); }
97859802SETS = kw :"SETS" i ! ident_part { return loc (createKeyword (kw)); }
97869803SHARE = kw :"SHARE" i ! ident_part { return loc (createKeyword (kw)); }
97879804SHARED = kw :"SHARED" i ! ident_part { return loc (createKeyword (kw)); }
0 commit comments