MCPcopy Create free account
hub / github.com/Effect-TS/effect / makeUnsafe

Function makeUnsafe

packages/effect/src/unstable/sql/Statement.ts:1241–1255  ·  view source on GitHub ↗
(
  segments: ReadonlyArray<Segment>,
  acquirer: Acquirer,
  compiler: Compiler,
  spanAttributes: ReadonlyArray<readonly [string, unknown]>,
  transformRows: (<A extends object>(row: ReadonlyArray<A>) => ReadonlyArray<A>) | undefined
)

Source from the content-addressed store, hash-verified

1239}
1240
1241const makeUnsafe = <A = Row>(
1242 segments: ReadonlyArray<Segment>,
1243 acquirer: Acquirer,
1244 compiler: Compiler,
1245 spanAttributes: ReadonlyArray<readonly [string, unknown]>,
1246 transformRows: (<A extends object>(row: ReadonlyArray<A>) => ReadonlyArray<A>) | undefined
1247): StatementImpl<A> => {
1248 const self = Object.create(StatementProto)
1249 self.segments = segments
1250 self.acquirer = acquirer
1251 self.compiler = compiler
1252 self.spanAttributes = spanAttributes
1253 self.transformRows = transformRows
1254 return self
1255}
1256
1257// TODO: figure out why these diagnostics are emitted
1258const StatementProto: Omit<

Callers 5

unsafeFunction · 0.70
statementFunction · 0.70
Chat.tsFile · 0.50
fromPromptFunction · 0.50
dateTime.tsFile · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected