MCPcopy Create free account
hub / github.com/auxten/postgresql-parser / NewFmtCtxEx

Function NewFmtCtxEx

pkg/sql/sem/tree/format.go:217–225  ·  view source on GitHub ↗

NewFmtCtxEx creates a FmtCtx.

(f FmtFlags, ann *Annotations)

Source from the content-addressed store, hash-verified

215
216// NewFmtCtxEx creates a FmtCtx.
217func NewFmtCtxEx(f FmtFlags, ann *Annotations) *FmtCtx {
218 if ann == nil && f&flagsRequiringAnnotations != 0 {
219 panic(errors.AssertionFailedf("no Annotations provided"))
220 }
221 ctx := fmtCtxPool.Get().(*FmtCtx)
222 ctx.flags = f
223 ctx.ann = ann
224 return ctx
225}
226
227// SetReformatTableNames modifies FmtCtx to to substitute the printing of table
228// names using the provided function.

Callers 2

NewFmtCtxFunction · 0.85
AsStringWithFQNamesFunction · 0.85

Calls 1

GetMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…