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

Function signatureFunctionThisKind

packages/tools/jsdocs/src/Jsdocs.ts:2838–2847  ·  view source on GitHub ↗
(type: ts.Type, checker: ts.TypeChecker, location: ts.Node)

Source from the content-addressed store, hash-verified

2836}
2837
2838function signatureFunctionThisKind(type: ts.Type, checker: ts.TypeChecker, location: ts.Node): string {
2839 const thisParameter = checker.getSignaturesOfType(type, ts.SignatureKind.Call)[0]?.thisParameter
2840 if (thisParameter === undefined) return "none"
2841 const thisType = checker.typeToString(
2842 checker.getTypeOfSymbolAtLocation(thisParameter, location),
2843 location,
2844 signatureTypeFormatFlags
2845 )
2846 return thisType === "unassigned" ? "unassigned" : "self"
2847}
2848
2849function isSignatureFunctionKind(kind: string): boolean {
2850 return kind.startsWith("body:") || kind.startsWith("function:")

Callers 1

signatureParameterKindFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected