MCPcopy
hub / github.com/sqlc-dev/sqlc / convertVar

Function convertVar

internal/engine/postgresql/convert.go:2828–2842  ·  view source on GitHub ↗
(n *pg.Var)

Source from the content-addressed store, hash-verified

2826}
2827
2828func convertVar(n *pg.Var) *ast.Var {
2829 if n == nil {
2830 return nil
2831 }
2832 return &ast.Var{
2833 Xpr: convertNode(n.Xpr),
2834 Varno: ast.Index(n.Varno),
2835 Varattno: ast.AttrNumber(n.Varattno),
2836 Vartype: ast.Oid(n.Vartype),
2837 Vartypmod: n.Vartypmod,
2838 Varcollid: ast.Oid(n.Varcollid),
2839 Varlevelsup: ast.Index(n.Varlevelsup),
2840 Location: int(n.Location),
2841 }
2842}
2843
2844func convertVariableSetStmt(n *pg.VariableSetStmt) *ast.VariableSetStmt {
2845 if n == nil {

Callers 1

convertNodeFunction · 0.85

Calls 4

IndexTypeAlias · 0.92
AttrNumberTypeAlias · 0.92
OidTypeAlias · 0.92
convertNodeFunction · 0.85

Tested by

no test coverage detected