(body: string)
| 4734 | // and emits `<receiver>.operator+` like any other member call. |
| 4735 | const HEADER = 'struct V {\n V operator+(const V& o) const;\n V operator[](int i) const;\n V operator()(int i) const;\n bool operator==(const V& o) const;\n int get() const;\n};\n'; |
| 4736 | const callRefsOf = (body: string) => |
| 4737 | extractFromSource('op.cpp', HEADER + body) |
| 4738 | .unresolvedReferences.filter((r) => r.referenceKind === 'calls') |
| 4739 | .map((r) => r.referenceName); |
| 4740 | |
| 4741 | it('recovers receiver.operator+ from the explicit call form', () => { |
| 4742 | expect(callRefsOf('V f(const V& a, const V& b) { return a.operator+(b); }\n')).toContain('a.operator+'); |
no test coverage detected