Skip to content

fix: correct C delegation and benchmark inputs in stats/strided/dpcorr#11890

Merged
kgryte merged 1 commit intodevelopfrom
philipp/fix-commit-review-2026-05-02
May 3, 2026
Merged

fix: correct C delegation and benchmark inputs in stats/strided/dpcorr#11890
kgryte merged 1 commit intodevelopfrom
philipp/fix-commit-review-2026-05-02

Conversation

@Planeshifter
Copy link
Copy Markdown
Member

Follow-up fixes for commits merged to develop between 2026-05-01 17:21 EDT (755a2ee2) and 2026-05-02 14:53 +0530 (6b8823ef).

Description

This pull request fixes two bugs introduced in the new stats/strided/dpcorr package (6b8823ef):

stats/strided/dpcorr

  • Fix missing API_SUFFIX(...) wrapper around stdlib_strided_dpcorrwd_ndarray call at lib/node_modules/@stdlib/stats/strided/dpcorr/src/main.c:53, introduced in 6b8823ef, causing resolution to a non-existent symbol when built against the 64-bit ABI.
  • Fix copy-paste bug in benchmark2 introduced in 6b8823ef, where stdlib_strided_dpcorr_ndarray was called with x passed for both array arguments instead of x and y, causing the benchmark to always compute the autocorrelation of x and leaving the allocated y array unused (lib/node_modules/@stdlib/stats/strided/dpcorr/benchmark/c/benchmark.length.c, line 155).

Related Issues

None.

Questions

No.

Other

Validation

The 19 commits in the window were audited by four review agents (two for stdlib code-style compliance, two for bugs). Both findings above were independently re-verified by reading the diff and comparing against sibling packages (stats/strided/dpcorrwd, stats/strided/dvariance).

Deliberately excluded from this PR:

  • repl.txt vs README.md discrepancy (N <= 0 vs N <= 1) in stats/strided/dpcorr — inherited verbatim from the stats/strided/dpcorrwd reference; out of scope for this window.
  • The same x-passed-twice pattern in stats/strided/dpcorrwd/benchmark/c/benchmark.length.c — outside the 24-hour diff window.
  • Hoisted done callback in _tools/github/star-repo/factory.js (c7a6b5c8) — closure refs verified intact; no action needed.
  • All Dependabot bumps, README structural sweeps, JSDoc @throws ordering, package.json keyword alignment, and the EditorConfig EOL fix — mechanical, no defects observed.

Checklist

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

This PR was authored primarily by Claude Code: a summary agent digested the last 24 hours of develop commits, four parallel review agents (two style, two bug-hunt) identified candidate issues, and the surviving high-signal findings were re-verified manually before applying the fixes. Each fix was confirmed against sibling-package patterns (stats/strided/dpcorrwd, stats/strided/dvariance) prior to commit.


@stdlib-js/reviewers


Generated by Claude Code

* In `src/main.c`, wrap the delegated `stdlib_strided_dpcorrwd_ndarray`
  call with `API_SUFFIX(...)` so the symbol resolves correctly when the
  64-bit indexing ABI is selected (matches the sibling pattern in
  `stats/strided/dvariance/src/main.c`).

* In `benchmark/c/benchmark.length.c`, pass `y` (not `x` twice) as the
  second strided array in `benchmark2`, otherwise the benchmark
  correlates `x` with itself and the allocated `y` is unused.

https://claude.ai/code/session_012VgKGaXwsACnoLu7UenrRc
@stdlib-bot stdlib-bot added the Statistics Issue or pull request related to statistical functionality. label May 2, 2026
@stdlib-bot
Copy link
Copy Markdown
Contributor

Coverage Report

Package Statements Branches Functions Lines
stats/strided/dpcorr $\color{green}363/363$
$\color{green}+100.00%$
$\color{green}13/13$
$\color{green}+100.00%$
$\color{green}4/4$
$\color{green}+100.00%$
$\color{green}363/363$
$\color{green}+100.00%$

The above coverage report was generated for the changes in this PR.

@Planeshifter Planeshifter marked this pull request as ready for review May 2, 2026 15:35
@Planeshifter Planeshifter requested review from a team and kgryte May 2, 2026 15:35
@stdlib-bot stdlib-bot added the Needs Review A pull request which needs code review. label May 2, 2026
@kgryte kgryte removed the Needs Review A pull request which needs code review. label May 3, 2026
@kgryte kgryte merged commit ec1d66c into develop May 3, 2026
56 checks passed
@kgryte kgryte deleted the philipp/fix-commit-review-2026-05-02 branch May 3, 2026 01:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Statistics Issue or pull request related to statistical functionality.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants