MCPcopy Create free account
hub / github.com/arktypeio/arktype / isDiscardedProtoMethodWrite

Function isDiscardedProtoMethodWrite

ark/aot/usage.ts:1441–1451  ·  view source on GitHub ↗
(
	member: Extract<Node, { type: "MemberExpression" }>
)

Source from the content-addressed store, hash-verified

1439}
1440
1441const isDiscardedProtoMethodWrite = (
1442 member: Extract<Node, { type: "MemberExpression" }>
1443): boolean => {
1444 const [operand, parent] = operatorOf(member)
1445 return (
1446 parent?.type === "AssignmentExpression" &&
1447 parent.operator === "=" &&
1448 parent.left === operand &&
1449 isDiscardedAssignment(parent)
1450 )
1451}
1452
1453const isSubProtoCreate = (
1454 operand: Node,

Callers 3

buildThisReadsContextFunction · 0.85
ctorExposesPrototypeFunction · 0.85
isDeadTopLevelFunctionFunction · 0.85

Calls 2

operatorOfFunction · 0.90
isDiscardedAssignmentFunction · 0.85

Tested by

no test coverage detected