MCPcopy Create free account
hub / github.com/dolthub/doltgresql / typeCheckSameTypedPlaceholders

Function typeCheckSameTypedPlaceholders

postgres/parser/sem/tree/type_check.go:2118–2127  ·  view source on GitHub ↗

Used to set placeholders to the desired typ.

(s typeCheckExprsState, typ *types.T)

Source from the content-addressed store, hash-verified

2116
2117// Used to set placeholders to the desired typ.
2118func typeCheckSameTypedPlaceholders(s typeCheckExprsState, typ *types.T) error {
2119 for _, i := range s.placeholderIdxs {
2120 typedExpr, err := typeCheckAndRequire(s.ctx, s.semaCtx, s.exprs[i], typ, "placeholder")
2121 if err != nil {
2122 return err
2123 }
2124 s.typedExprs[i] = typedExpr
2125 }
2126 return nil
2127}
2128
2129// Used to type check constants to the same type. An optional typ can be
2130// provided to signify the desired shared type, which can be set to the

Calls 1

typeCheckAndRequireFunction · 0.85

Tested by

no test coverage detected