@@ -32,6 +32,7 @@ use super::{value::escape_single_quote_string, ColumnDef};
3232#[ derive( Debug , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
3333#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
3434#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
35+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_enum_member" ) ) ]
3536/// A member of an ENUM type.
3637pub enum EnumMember {
3738 /// Just a name.
@@ -46,6 +47,7 @@ pub enum EnumMember {
4647#[ derive( Debug , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
4748#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
4849#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
50+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_data_type" ) ) ]
4951pub enum DataType {
5052 /// Table type in [PostgreSQL], e.g. CREATE FUNCTION RETURNS TABLE(...).
5153 ///
@@ -897,6 +899,7 @@ fn format_clickhouse_datetime_precision_and_timezone(
897899#[ derive( Debug , Clone , Copy , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
898900#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
899901#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
902+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_struct_bracket_kind" ) ) ]
900903pub enum StructBracketKind {
901904 /// Example: `STRUCT(a INT, b STRING)`
902905 Parentheses ,
@@ -911,6 +914,7 @@ pub enum StructBracketKind {
911914#[ derive( Debug , Copy , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
912915#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
913916#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
917+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_timezone_info" ) ) ]
914918pub enum TimezoneInfo {
915919 /// No information about time zone, e.g. TIMESTAMP
916920 None ,
@@ -1014,6 +1018,7 @@ impl fmt::Display for IntervalFields {
10141018#[ derive( Debug , Copy , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
10151019#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
10161020#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
1021+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_exact_number_info" ) ) ]
10171022pub enum ExactNumberInfo {
10181023 /// No additional information, e.g. `DECIMAL`.
10191024 None ,
@@ -1045,6 +1050,7 @@ impl fmt::Display for ExactNumberInfo {
10451050#[ derive( Debug , Copy , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
10461051#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
10471052#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
1053+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_character_length" ) ) ]
10481054pub enum CharacterLength {
10491055 /// Integer length with optional unit (e.g. `CHAR(10)` or `VARCHAR(10 CHARACTERS)`).
10501056 IntegerLength {
@@ -1080,6 +1086,7 @@ impl fmt::Display for CharacterLength {
10801086#[ derive( Debug , Copy , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
10811087#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
10821088#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
1089+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_char_length_units" ) ) ]
10831090pub enum CharLengthUnits {
10841091 /// CHARACTERS unit
10851092 Characters ,
@@ -1103,6 +1110,7 @@ impl fmt::Display for CharLengthUnits {
11031110#[ derive( Debug , Copy , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
11041111#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
11051112#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
1113+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_binary_length" ) ) ]
11061114/// Information about [binary length][1], including length and possibly unit.
11071115///
11081116/// [1]: https://jakewheat.github.io/sql-overview/sql-2016-foundation-grammar.html#binary-length
@@ -1137,6 +1145,7 @@ impl fmt::Display for BinaryLength {
11371145#[ derive( Debug , Clone , PartialEq , PartialOrd , Eq , Ord , Hash ) ]
11381146#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
11391147#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
1148+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_array_elem_type_def" ) ) ]
11401149pub enum ArrayElemTypeDef {
11411150 /// Use `ARRAY` style without an explicit element type.
11421151 None ,
@@ -1155,6 +1164,7 @@ pub enum ArrayElemTypeDef {
11551164#[ derive( Debug , Copy , Clone , PartialEq , Eq , Hash , PartialOrd , Ord ) ]
11561165#[ cfg_attr( feature = "serde" , derive( Serialize , Deserialize ) ) ]
11571166#[ cfg_attr( feature = "visitor" , derive( Visit , VisitMut ) ) ]
1167+ #[ cfg_attr( feature = "visitor" , visit( with = "visit_geometric_type_kind" ) ) ]
11581168pub enum GeometricTypeKind {
11591169 /// Point geometry
11601170 Point ,
0 commit comments