Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update codegen sources #34

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion codegen/src/errcodes.txt
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
# errcodes.txt
# PostgreSQL error codes
#
# Copyright (c) 2003-2022, PostgreSQL Global Development Group
# Copyright (c) 2003-2024, PostgreSQL Global Development Group
#
# This list serves as the basis for generating source files containing error
# codes. It is kept in a common format to make sure all these source files have
@@ -252,6 +252,7 @@ Section: Class 25 - Invalid Transaction State
25P01 E ERRCODE_NO_ACTIVE_SQL_TRANSACTION no_active_sql_transaction
25P02 E ERRCODE_IN_FAILED_SQL_TRANSACTION in_failed_sql_transaction
25P03 E ERRCODE_IDLE_IN_TRANSACTION_SESSION_TIMEOUT idle_in_transaction_session_timeout
25P04 E ERRCODE_TRANSACTION_TIMEOUT transaction_timeout

Section: Class 26 - Invalid SQL Statement Name

2 changes: 1 addition & 1 deletion codegen/src/pg_range.dat
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@
# pg_range.dat
# Initial contents of the pg_range system catalog.
#
# Portions Copyright (c) 1996-2022, PostgreSQL Global Development Group
# Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/include/catalog/pg_range.dat
47 changes: 25 additions & 22 deletions codegen/src/pg_type.dat
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@
# pg_type.dat
# Initial contents of the pg_type system catalog.
#
# Portions Copyright (c) 1996-2022, PostgreSQL Global Development Group
# Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
# Portions Copyright (c) 1994, Regents of the University of California
#
# src/include/catalog/pg_type.dat
@@ -32,7 +32,7 @@
# OIDS 1 - 99

{ oid => '16', array_type_oid => '1000',
descr => 'boolean, \'true\'/\'false\'',
descr => 'boolean, format \'t\'/\'f\'',
typname => 'bool', typlen => '1', typbyval => 't', typcategory => 'B',
typispreferred => 't', typinput => 'boolin', typoutput => 'boolout',
typreceive => 'boolrecv', typsend => 'boolsend', typalign => 'c' },
@@ -90,7 +90,7 @@
typispreferred => 't', typinput => 'oidin', typoutput => 'oidout',
typreceive => 'oidrecv', typsend => 'oidsend', typalign => 'i' },
{ oid => '27', array_type_oid => '1010',
descr => '(block, offset), physical location of tuple',
descr => 'tuple physical location, format \'(block,offset)\'',
typname => 'tid', typlen => '6', typbyval => 'f', typcategory => 'U',
typinput => 'tidin', typoutput => 'tidout', typreceive => 'tidrecv',
typsend => 'tidsend', typalign => 's' },
@@ -179,34 +179,35 @@
# OIDS 600 - 699

{ oid => '600', array_type_oid => '1017',
descr => 'geometric point \'(x, y)\'',
descr => 'geometric point, format \'(x,y)\'',
typname => 'point', typlen => '16', typbyval => 'f', typcategory => 'G',
typsubscript => 'raw_array_subscript_handler', typelem => 'float8',
typinput => 'point_in', typoutput => 'point_out', typreceive => 'point_recv',
typsend => 'point_send', typalign => 'd' },
{ oid => '601', array_type_oid => '1018',
descr => 'geometric line segment \'(pt1,pt2)\'',
descr => 'geometric line segment, format \'[point1,point2]\'',
typname => 'lseg', typlen => '32', typbyval => 'f', typcategory => 'G',
typsubscript => 'raw_array_subscript_handler', typelem => 'point',
typinput => 'lseg_in', typoutput => 'lseg_out', typreceive => 'lseg_recv',
typsend => 'lseg_send', typalign => 'd' },
{ oid => '602', array_type_oid => '1019',
descr => 'geometric path \'(pt1,...)\'',
descr => 'geometric path, format \'(point1,...)\'',
typname => 'path', typlen => '-1', typbyval => 'f', typcategory => 'G',
typinput => 'path_in', typoutput => 'path_out', typreceive => 'path_recv',
typsend => 'path_send', typalign => 'd', typstorage => 'x' },
{ oid => '603', array_type_oid => '1020',
descr => 'geometric box \'(lower left,upper right)\'',
descr => 'geometric box, format \'lower left point,upper right point\'',
typname => 'box', typlen => '32', typbyval => 'f', typcategory => 'G',
typdelim => ';', typsubscript => 'raw_array_subscript_handler',
typelem => 'point', typinput => 'box_in', typoutput => 'box_out',
typreceive => 'box_recv', typsend => 'box_send', typalign => 'd' },
{ oid => '604', array_type_oid => '1027',
descr => 'geometric polygon \'(pt1,...)\'',
descr => 'geometric polygon, format \'(point1,...)\'',
typname => 'polygon', typlen => '-1', typbyval => 'f', typcategory => 'G',
typinput => 'poly_in', typoutput => 'poly_out', typreceive => 'poly_recv',
typsend => 'poly_send', typalign => 'd', typstorage => 'x' },
{ oid => '628', array_type_oid => '629', descr => 'geometric line',
{ oid => '628', array_type_oid => '629',
descr => 'geometric line, formats \'{A,B,C}\'/\'[point1,point2]\'',
typname => 'line', typlen => '24', typbyval => 'f', typcategory => 'G',
typsubscript => 'raw_array_subscript_handler', typelem => 'float8',
typinput => 'line_in', typoutput => 'line_out', typreceive => 'line_recv',
@@ -230,7 +231,7 @@
typcategory => 'X', typinput => 'unknownin', typoutput => 'unknownout',
typreceive => 'unknownrecv', typsend => 'unknownsend', typalign => 'c' },
{ oid => '718', array_type_oid => '719',
descr => 'geometric circle \'(center,radius)\'',
descr => 'geometric circle, format \'<center point,radius>\'',
typname => 'circle', typlen => '24', typbyval => 'f', typcategory => 'G',
typinput => 'circle_in', typoutput => 'circle_out',
typreceive => 'circle_recv', typsend => 'circle_send', typalign => 'd' },
@@ -267,18 +268,18 @@
# OIDS 1000 - 1099

{ oid => '1033', array_type_oid => '1034', descr => 'access control list',
typname => 'aclitem', typlen => '12', typbyval => 'f', typcategory => 'U',
typname => 'aclitem', typlen => '16', typbyval => 'f', typcategory => 'U',
typinput => 'aclitemin', typoutput => 'aclitemout', typreceive => '-',
typsend => '-', typalign => 'i' },
typsend => '-', typalign => 'd' },
{ oid => '1042', array_type_oid => '1014',
descr => 'char(length), blank-padded string, fixed storage length',
descr => '\'char(length)\' blank-padded string, fixed storage length',
typname => 'bpchar', typlen => '-1', typbyval => 'f', typcategory => 'S',
typinput => 'bpcharin', typoutput => 'bpcharout', typreceive => 'bpcharrecv',
typsend => 'bpcharsend', typmodin => 'bpchartypmodin',
typmodout => 'bpchartypmodout', typalign => 'i', typstorage => 'x',
typcollation => 'default' },
{ oid => '1043', array_type_oid => '1015',
descr => 'varchar(length), non-blank-padded string, variable storage length',
descr => '\'varchar(length)\' non-blank-padded string, variable storage length',
typname => 'varchar', typlen => '-1', typbyval => 'f', typcategory => 'S',
typinput => 'varcharin', typoutput => 'varcharout',
typreceive => 'varcharrecv', typsend => 'varcharsend',
@@ -310,7 +311,7 @@
typsend => 'timestamptz_send', typmodin => 'timestamptztypmodin',
typmodout => 'timestamptztypmodout', typalign => 'd' },
{ oid => '1186', array_type_oid => '1187',
descr => '@ <number> <units>, time interval',
descr => 'time interval, format \'number units ...\'',
typname => 'interval', typlen => '16', typbyval => 'f', typcategory => 'T',
typispreferred => 't', typinput => 'interval_in', typoutput => 'interval_out',
typreceive => 'interval_recv', typsend => 'interval_send',
@@ -345,7 +346,7 @@
# OIDS 1700 - 1799

{ oid => '1700', array_type_oid => '1231',
descr => 'numeric(precision, decimal), arbitrary precision number',
descr => '\'numeric(precision, scale)\' arbitrary precision number',
typname => 'numeric', typlen => '-1', typbyval => 'f', typcategory => 'N',
typinput => 'numeric_in', typoutput => 'numeric_out',
typreceive => 'numeric_recv', typsend => 'numeric_send',
@@ -400,13 +401,13 @@
typalign => 'i' },

# uuid
{ oid => '2950', array_type_oid => '2951', descr => 'UUID datatype',
{ oid => '2950', array_type_oid => '2951', descr => 'UUID',
typname => 'uuid', typlen => '16', typbyval => 'f', typcategory => 'U',
typinput => 'uuid_in', typoutput => 'uuid_out', typreceive => 'uuid_recv',
typsend => 'uuid_send', typalign => 'c' },

# pg_lsn
{ oid => '3220', array_type_oid => '3221', descr => 'PostgreSQL LSN datatype',
{ oid => '3220', array_type_oid => '3221', descr => 'PostgreSQL LSN',
typname => 'pg_lsn', typlen => '8', typbyval => 'FLOAT8PASSBYVAL',
typcategory => 'U', typinput => 'pg_lsn_in', typoutput => 'pg_lsn_out',
typreceive => 'pg_lsn_recv', typsend => 'pg_lsn_send', typalign => 'd' },
@@ -452,12 +453,12 @@
typreceive => 'jsonpath_recv', typsend => 'jsonpath_send', typalign => 'i',
typstorage => 'x' },

{ oid => '2970', array_type_oid => '2949', descr => 'txid snapshot',
{ oid => '2970', array_type_oid => '2949', descr => 'transaction snapshot',
typname => 'txid_snapshot', typlen => '-1', typbyval => 'f',
typcategory => 'U', typinput => 'txid_snapshot_in',
typoutput => 'txid_snapshot_out', typreceive => 'txid_snapshot_recv',
typsend => 'txid_snapshot_send', typalign => 'd', typstorage => 'x' },
{ oid => '5038', array_type_oid => '5039', descr => 'snapshot',
{ oid => '5038', array_type_oid => '5039', descr => 'transaction snapshot',
typname => 'pg_snapshot', typlen => '-1', typbyval => 'f', typcategory => 'U',
typinput => 'pg_snapshot_in', typoutput => 'pg_snapshot_out',
typreceive => 'pg_snapshot_recv', typsend => 'pg_snapshot_send',
@@ -633,6 +634,7 @@
typoutput => 'tsm_handler_out', typreceive => '-', typsend => '-',
typalign => 'i' },
{ oid => '269',
descr => 'pseudo-type for the result of a table AM handler function',
typname => 'table_am_handler', typlen => '4', typbyval => 't', typtype => 'p',
typcategory => 'P', typinput => 'table_am_handler_in',
typoutput => 'table_am_handler_out', typreceive => '-', typsend => '-',
@@ -679,13 +681,14 @@
typtype => 'p', typcategory => 'P', typinput => 'anycompatiblemultirange_in',
typoutput => 'anycompatiblemultirange_out', typreceive => '-', typsend => '-',
typalign => 'd', typstorage => 'x' },
{ oid => '4600', descr => 'BRIN bloom summary',
{ oid => '4600', descr => 'pseudo-type representing BRIN bloom summary',
typname => 'pg_brin_bloom_summary', typlen => '-1', typbyval => 'f',
typcategory => 'Z', typinput => 'brin_bloom_summary_in',
typoutput => 'brin_bloom_summary_out',
typreceive => 'brin_bloom_summary_recv', typsend => 'brin_bloom_summary_send',
typalign => 'i', typstorage => 'x', typcollation => 'default' },
{ oid => '4601', descr => 'BRIN minmax-multi summary',
{ oid => '4601',
descr => 'pseudo-type representing BRIN minmax-multi summary',
typname => 'pg_brin_minmax_multi_summary', typlen => '-1', typbyval => 'f',
typcategory => 'Z', typinput => 'brin_minmax_multi_summary_in',
typoutput => 'brin_minmax_multi_summary_out',
40 changes: 20 additions & 20 deletions postgres-types/src/type_gen.rs
Original file line number Diff line number Diff line change
@@ -967,7 +967,7 @@ impl Inner {
}
}
impl Type {
/// BOOL - boolean, &#39;true&#39;/&#39;false&#39;
/// BOOL - boolean, format &#39;t&#39;/&#39;f&#39;
pub const BOOL: Type = Type(Inner::Bool);

/// BYTEA - variable-length string, binary values escaped
@@ -1000,7 +1000,7 @@ impl Type {
/// OID - object identifier&#40;oid&#41;, maximum 4 billion
pub const OID: Type = Type(Inner::Oid);

/// TID - &#40;block, offset&#41;, physical location of tuple
/// TID - tuple physical location, format &#39;&#40;block,offset&#41;&#39;
pub const TID: Type = Type(Inner::Tid);

/// XID - transaction id
@@ -1030,7 +1030,7 @@ impl Type {
/// JSON&#91;&#93;
pub const JSON_ARRAY: Type = Type(Inner::JsonArray);

/// TABLE_AM_HANDLER
/// TABLE_AM_HANDLER - pseudo-type for the result of a table AM handler function
pub const TABLE_AM_HANDLER: Type = Type(Inner::TableAmHandler);

/// XID8&#91;&#93;
@@ -1039,22 +1039,22 @@ impl Type {
/// INDEX_AM_HANDLER - pseudo-type for the result of an index AM handler function
pub const INDEX_AM_HANDLER: Type = Type(Inner::IndexAmHandler);

/// POINT - geometric point &#39;&#40;x, y&#41;&#39;
/// POINT - geometric point, format &#39;&#40;x,y&#41;&#39;
pub const POINT: Type = Type(Inner::Point);

/// LSEG - geometric line segment &#39;&#40;pt1,pt2&#41;&#39;
/// LSEG - geometric line segment, format &#39;&#91;point1,point2&#93;&#39;
pub const LSEG: Type = Type(Inner::Lseg);

/// PATH - geometric path &#39;&#40;pt1,...&#41;&#39;
/// PATH - geometric path, format &#39;&#40;point1,...&#41;&#39;
pub const PATH: Type = Type(Inner::Path);

/// BOX - geometric box &#39;&#40;lower left,upper right&#41;&#39;
/// BOX - geometric box, format &#39;lower left point,upper right point&#39;
pub const BOX: Type = Type(Inner::Box);

/// POLYGON - geometric polygon &#39;&#40;pt1,...&#41;&#39;
/// POLYGON - geometric polygon, format &#39;&#40;point1,...&#41;&#39;
pub const POLYGON: Type = Type(Inner::Polygon);

/// LINE - geometric line
/// LINE - geometric line, formats &#39;&#123;A,B,C&#125;&#39;/&#39;&#91;point1,point2&#93;&#39;
pub const LINE: Type = Type(Inner::Line);

/// LINE&#91;&#93;
@@ -1075,7 +1075,7 @@ impl Type {
/// UNKNOWN - pseudo-type representing an undetermined type
pub const UNKNOWN: Type = Type(Inner::Unknown);

/// CIRCLE - geometric circle &#39;&#40;center,radius&#41;&#39;
/// CIRCLE - geometric circle, format &#39;&lt;center point,radius&gt;&#39;
pub const CIRCLE: Type = Type(Inner::Circle);

/// CIRCLE&#91;&#93;
@@ -1183,10 +1183,10 @@ impl Type {
/// INET&#91;&#93;
pub const INET_ARRAY: Type = Type(Inner::InetArray);

/// BPCHAR - char&#40;length&#41;, blank-padded string, fixed storage length
/// BPCHAR - &#39;char&#40;length&#41;&#39; blank-padded string, fixed storage length
pub const BPCHAR: Type = Type(Inner::Bpchar);

/// VARCHAR - varchar&#40;length&#41;, non-blank-padded string, variable storage length
/// VARCHAR - &#39;varchar&#40;length&#41;&#39; non-blank-padded string, variable storage length
pub const VARCHAR: Type = Type(Inner::Varchar);

/// DATE - date
@@ -1213,7 +1213,7 @@ impl Type {
/// TIMESTAMPTZ&#91;&#93;
pub const TIMESTAMPTZ_ARRAY: Type = Type(Inner::TimestamptzArray);

/// INTERVAL - &#64; &lt;number&gt; &lt;units&gt;, time interval
/// INTERVAL - time interval, format &#39;number units ...&#39;
pub const INTERVAL: Type = Type(Inner::Interval);

/// INTERVAL&#91;&#93;
@@ -1243,7 +1243,7 @@ impl Type {
/// VARBIT&#91;&#93;
pub const VARBIT_ARRAY: Type = Type(Inner::VarbitArray);

/// NUMERIC - numeric&#40;precision, decimal&#41;, arbitrary precision number
/// NUMERIC - &#39;numeric&#40;precision, scale&#41;&#39; arbitrary precision number
pub const NUMERIC: Type = Type(Inner::Numeric);

/// REFCURSOR - reference to cursor &#40;portal name&#41;
@@ -1318,19 +1318,19 @@ impl Type {
/// TXID_SNAPSHOT&#91;&#93;
pub const TXID_SNAPSHOT_ARRAY: Type = Type(Inner::TxidSnapshotArray);

/// UUID - UUID datatype
/// UUID - UUID
pub const UUID: Type = Type(Inner::Uuid);

/// UUID&#91;&#93;
pub const UUID_ARRAY: Type = Type(Inner::UuidArray);

/// TXID_SNAPSHOT - txid snapshot
/// TXID_SNAPSHOT - transaction snapshot
pub const TXID_SNAPSHOT: Type = Type(Inner::TxidSnapshot);

/// FDW_HANDLER - pseudo-type for the result of an FDW handler function
pub const FDW_HANDLER: Type = Type(Inner::FdwHandler);

/// PG_LSN - PostgreSQL LSN datatype
/// PG_LSN - PostgreSQL LSN
pub const PG_LSN: Type = Type(Inner::PgLsn);

/// PG_LSN&#91;&#93;
@@ -1474,16 +1474,16 @@ impl Type {
/// ANYCOMPATIBLEMULTIRANGE - pseudo-type representing a multirange over a polymorphic common type
pub const ANYCOMPATIBLEMULTI_RANGE: Type = Type(Inner::AnycompatiblemultiRange);

/// PG_BRIN_BLOOM_SUMMARY - BRIN bloom summary
/// PG_BRIN_BLOOM_SUMMARY - pseudo-type representing BRIN bloom summary
pub const PG_BRIN_BLOOM_SUMMARY: Type = Type(Inner::PgBrinBloomSummary);

/// PG_BRIN_MINMAX_MULTI_SUMMARY - BRIN minmax-multi summary
/// PG_BRIN_MINMAX_MULTI_SUMMARY - pseudo-type representing BRIN minmax-multi summary
pub const PG_BRIN_MINMAX_MULTI_SUMMARY: Type = Type(Inner::PgBrinMinmaxMultiSummary);

/// PG_MCV_LIST - multivariate MCV list
pub const PG_MCV_LIST: Type = Type(Inner::PgMcvList);

/// PG_SNAPSHOT - snapshot
/// PG_SNAPSHOT - transaction snapshot
pub const PG_SNAPSHOT: Type = Type(Inner::PgSnapshot);

/// PG_SNAPSHOT&#91;&#93;
Loading