MCPcopy
hub / github.com/angular/angular / isEquivalent

Method isEquivalent

packages/compiler/src/output/output_ast.ts:1090–1104  ·  view source on GitHub ↗
(e: Expression)

Source from the content-addressed store, hash-verified

1088 }
1089
1090 override isEquivalent(e: Expression): boolean {
1091 if (!(e instanceof ArrowFunctionExpr) || !areAllEquivalent(this.params, e.params)) {
1092 return false;
1093 }
1094
1095 if (this.body instanceof Expression && e.body instanceof Expression) {
1096 return this.body.isEquivalent(e.body);
1097 }
1098
1099 if (Array.isArray(this.body) && Array.isArray(e.body)) {
1100 return areAllEquivalent(this.body, e.body);
1101 }
1102
1103 return false;
1104 }
1105
1106 override isConstant(): boolean {
1107 return false;

Callers

nothing calls this directly

Calls 3

areAllEquivalentFunction · 0.85
isArrayMethod · 0.80
isEquivalentMethod · 0.45

Tested by

no test coverage detected