From 91a8e03bbe729c096a0c625b1a9ffcaaee94d219 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 13 May 2026 12:51:49 +0000 Subject: [PATCH] chore(autofix): apply prettier + eslint fixes via /autofix command --- .../languages/cpp/file-local-linkage.ts | 10 ++++-- .../passes/receiver-bound-calls.ts | 5 ++- .../test/integration/resolvers/cpp.test.ts | 31 +++++-------------- 3 files changed, 19 insertions(+), 27 deletions(-) diff --git a/gitnexus/src/core/ingestion/languages/cpp/file-local-linkage.ts b/gitnexus/src/core/ingestion/languages/cpp/file-local-linkage.ts index 6ab3bbdaf..93363e6a8 100644 --- a/gitnexus/src/core/ingestion/languages/cpp/file-local-linkage.ts +++ b/gitnexus/src/core/ingestion/languages/cpp/file-local-linkage.ts @@ -68,7 +68,10 @@ export function clearFileLocalNames(): void { */ export function populateCppNonGloballyVisible(parsed: { readonly filePath: string; - readonly scopes: readonly { readonly kind: string; readonly ownedDefs: readonly { readonly nodeId: string }[] }[]; + readonly scopes: readonly { + readonly kind: string; + readonly ownedDefs: readonly { readonly nodeId: string }[]; + }[]; }): void { let set = nonGloballyVisibleNodeIds.get(parsed.filePath); if (set === undefined) { @@ -182,7 +185,10 @@ export function expandCppWildcardNames( // include (preserves prior behavior for any def whose structural // ownership wasn't recorded in `Scope.ownedDefs`). const ownerScope = ownerScopeByNodeId.get(def.nodeId); - if (ownerScope !== undefined && (ownerScope.kind === 'Namespace' || ownerScope.kind === 'Class')) { + if ( + ownerScope !== undefined && + (ownerScope.kind === 'Namespace' || ownerScope.kind === 'Class') + ) { continue; } diff --git a/gitnexus/src/core/ingestion/scope-resolution/passes/receiver-bound-calls.ts b/gitnexus/src/core/ingestion/scope-resolution/passes/receiver-bound-calls.ts index e4178373c..b670279ff 100644 --- a/gitnexus/src/core/ingestion/scope-resolution/passes/receiver-bound-calls.ts +++ b/gitnexus/src/core/ingestion/scope-resolution/passes/receiver-bound-calls.ts @@ -51,7 +51,10 @@ import { import { tryEmitEdge } from '../graph-bridge/edges.js'; import { resolveCompoundReceiverClass } from '../passes/compound-receiver.js'; import { resolveDefGraphId } from '../graph-bridge/ids.js'; -import { narrowOverloadCandidates, isOverloadAmbiguousAfterNormalization } from './overload-narrowing.js'; +import { + narrowOverloadCandidates, + isOverloadAmbiguousAfterNormalization, +} from './overload-narrowing.js'; /** Subset of `ScopeResolver` consumed by this pass. Accepting the * subset rather than the full provider keeps tests and partial diff --git a/gitnexus/test/integration/resolvers/cpp.test.ts b/gitnexus/test/integration/resolvers/cpp.test.ts index 30ff25181..7423fbb54 100644 --- a/gitnexus/test/integration/resolvers/cpp.test.ts +++ b/gitnexus/test/integration/resolvers/cpp.test.ts @@ -1597,10 +1597,7 @@ describe('C++ include does not leak class methods', () => { let result: PipelineResult; beforeAll(async () => { - result = await runPipelineFromRepo( - path.join(FIXTURES, 'cpp-include-no-class-leak'), - () => {}, - ); + result = await runPipelineFromRepo(path.join(FIXTURES, 'cpp-include-no-class-leak'), () => {}); }, 60000); it('does NOT resolve unqualified save() to User::save via #include', () => { @@ -1674,10 +1671,7 @@ describe('C++ ambiguous integer-width overloads', () => { let result: PipelineResult; beforeAll(async () => { - result = await runPipelineFromRepo( - path.join(FIXTURES, 'cpp-overload-int-long'), - () => {}, - ); + result = await runPipelineFromRepo(path.join(FIXTURES, 'cpp-overload-int-long'), () => {}); }, 60000); it('emits zero CALLS edges when process(int)/process(long) collide after normalization', () => { @@ -1700,19 +1694,14 @@ describe('C++ anonymous namespace cross-file exclusion (integration)', () => { let result: PipelineResult; beforeAll(async () => { - result = await runPipelineFromRepo( - path.join(FIXTURES, 'cpp-anon-ns-cross-file'), - () => {}, - ); + result = await runPipelineFromRepo(path.join(FIXTURES, 'cpp-anon-ns-cross-file'), () => {}); }, 60000); it('caller.cpp::run -> worker does NOT target helper.cpp anonymous-namespace worker', () => { const calls = getRelationships(result, 'CALLS'); const crossFileLeak = calls.filter( (c) => - c.source === 'run' && - c.target === 'worker' && - c.targetFilePath?.includes('helper.cpp'), + c.source === 'run' && c.target === 'worker' && c.targetFilePath?.includes('helper.cpp'), ); expect(crossFileLeak.length).toBe(0); }); @@ -1743,9 +1732,7 @@ describe('C++ anonymous namespace state-isolation guard', () => { const countLeak = (r: PipelineResult): number => getRelationships(r, 'CALLS').filter( (c) => - c.source === 'run' && - c.target === 'worker' && - c.targetFilePath?.includes('helper.cpp'), + c.source === 'run' && c.target === 'worker' && c.targetFilePath?.includes('helper.cpp'), ).length; expect(countLeak(r1)).toBe(0); expect(countLeak(r2)).toBe(0); @@ -1800,18 +1787,14 @@ describe('C++ using-namespace std smoke test', () => { it('resolves the project call (positive guard against vacuous pass)', () => { const calls = getRelationships(result, 'CALLS'); - const projectCalls = calls.filter( - (c) => c.source === 'run' && c.target === 'project_helper', - ); + const projectCalls = calls.filter((c) => c.source === 'run' && c.target === 'project_helper'); expect(projectCalls.length).toBe(1); }); it('does NOT leak unqualified bindings for shim STL symbols', () => { const calls = getRelationships(result, 'CALLS'); const stlLeaks = calls.filter( - (c) => - c.source === 'run' && - (c.target === 'cout_write' || c.target === 'println'), + (c) => c.source === 'run' && (c.target === 'cout_write' || c.target === 'println'), ); expect(stlLeaks.length).toBe(0); });