MCPcopy Create free account
hub / github.com/cockroachdb/cockroachdb-parser / NewTypedCastExpr

Function NewTypedCastExpr

pkg/sql/sem/tree/expr.go:1561–1565  ·  view source on GitHub ↗

NewTypedCastExpr returns a new CastExpr that is verified to be well-typed.

(expr TypedExpr, typ *types.T)

Source from the content-addressed store, hash-verified

1559
1560// NewTypedCastExpr returns a new CastExpr that is verified to be well-typed.
1561func NewTypedCastExpr(expr TypedExpr, typ *types.T) *CastExpr {
1562 node := &CastExpr{Expr: expr, Type: typ, SyntaxMode: CastShort}
1563 node.typ = typ
1564 return node
1565}
1566
1567// ArraySubscripts represents a sequence of one or more array subscripts.
1568type ArraySubscripts []*ArraySubscript

Callers 3

ResolveAsTypeMethod · 0.85
TypeCheckMethod · 0.85
typeCheckSameTypedExprsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…