refactor(pkg): canonicalize base types and adjust length handling
* Update base types to keep explicit modifier forms * Modify length handling for vector types in tests
This commit is contained in:
@@ -804,6 +804,7 @@ func (r *Reader) parseTypeWithLength(typeStr string) (baseType string, length in
|
||||
// This avoids converting custom modifiers like vector(1536) into Length.
|
||||
if pgsql.SupportsLength(rawBaseType) && !strings.Contains(parens, ",") {
|
||||
if _, err := fmt.Sscanf(parens, "%d", &length); err == nil {
|
||||
baseType = pgsql.CanonicalizeBaseType(rawBaseType)
|
||||
return
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user