github.com/cockroachdb/cockroachdb-parser@v0.23.3-0.20240213214944-911057d40c9a/patches/0002-fix-quote-names.patch (about)

     1  diff --git a/pkg/sql/sem/tree/type_name.go b/pkg/sql/sem/tree/type_name.go
     2  index a671b41..51e484b 100644
     3  --- a/pkg/sql/sem/tree/type_name.go
     4  +++ b/pkg/sql/sem/tree/type_name.go
     5  @@ -48,7 +48,7 @@ func (t *TypeName) Format(ctx *FmtCtx) {
     6   // SQLString implements the ResolvableTypeReference interface.
     7   func (t *TypeName) SQLString() string {
     8   	// FmtBareIdentifiers prevents the TypeName string from being wrapped in quotations.
     9  -	return AsStringWithFlags(t, FmtBareIdentifiers)
    10  +	return AsStringWithFlags(t, FmtSimple)
    11   }
    12   
    13   func (t *TypeName) objectName() {}
    14  @@ -240,13 +240,13 @@ func (node *ArrayTypeReference) Format(ctx *FmtCtx) {
    15   // SQLString implements the ResolvableTypeReference interface.
    16   func (node *ArrayTypeReference) SQLString() string {
    17   	// FmtBareIdentifiers prevents the TypeName string from being wrapped in quotations.
    18  -	return AsStringWithFlags(node, FmtBareIdentifiers)
    19  +	return AsStringWithFlags(node, FmtSimple)
    20   }
    21   
    22   // SQLString implements the ResolvableTypeReference interface.
    23   func (name *UnresolvedObjectName) SQLString() string {
    24   	// FmtBareIdentifiers prevents the TypeName string from being wrapped in quotations.
    25  -	return AsStringWithFlags(name, FmtBareIdentifiers)
    26  +	return AsStringWithFlags(name, FmtSimple)
    27   }
    28   
    29   // IsReferenceSerialType returns whether the input reference is a known