docs: fix TSDoc issues across many math/base/special declarations#12467
Draft
Planeshifter wants to merge 1 commit into
Draft
docs: fix TSDoc issues across many math/base/special declarations#12467Planeshifter wants to merge 1 commit into
math/base/special declarations#12467Planeshifter wants to merge 1 commit into
Conversation
Contributor
Coverage Report
The above coverage report was generated for the changes in this PR. |
ee5bdc1 to
796b024
Compare
7 tasks
…ations
Correct documentation-only issues in the TypeScript declaration files
flagged by an audit of the `@stdlib/math/base/special` namespace. No
emitted types change in a behavior-affecting way; the edits are limited
to TSDoc prose, examples, parameter names/descriptions, and internal
interface names.
Highlights:
- `kernel-betainc`: the 4th/5th parameters were named `invert`/
`normalized` with descriptions swapped relative to the implementation
`kernelBetainc( x, a, b, regularized, upper )`; rename to
`regularized`/`upper` and re-pair the descriptions, fix the garbled
"regularized boolean beta function" -> "incomplete beta function" (in
the declaration and the `lib/main.js`/`lib/assign.js` JSDoc), and fix
the interface doc comment misspelling `kernalBetaInc`.
- `gammainc`: split the muddled `regularized`/`upper` Notes into two
clear bullets and fix a stale `s <= 0` -> `a <= 0` reference.
- `cfloor`: summary now says "Rounds each component of..." like its
siblings; `cpolarf`/`sincosd`: fix copy-pasted/lowercase interface
names (`Cpolar` -> `Cpolarf`, `sincosd` -> `SinCosd`).
- `minmax`/`minmaxn`/`minmaxf`/`sincospi`: `assign` `@example`s now call
the `.assign` method instead of the bare function (so `v === out` is
actually `true`); correct the `assign` summary/`@returns` for
`sincospi`; split merged `@example` blocks.
- `minabs`: drop the empty-set Notes paragraph (the function is binary);
`minabsn`/`maxabsn`/`minmaxabsn`: correct the empty-args identity
Notes (a minimum's bound is the greatest *lower* bound; the absolute
maximum's empty result follows from the `-infinity` identity).
- `covercos`/`coversin`/`havercos`: add the defining-formula Notes block
their forward-trig siblings include.
- Assorted prose fixes: `frexp`/`frexpf` "Inteface" typo, `absf`/
`acsch`/`asech`/`negalucasf` summary wording, `floorn` summary
("numeric value", matching `ceiln`/`roundn`/`truncn`), `cotd`/`tand`
trailing periods, `cround` unused requires, `gammaincinv`
argument-order notation, `lnf`/`round` `@returns`, `truncsd`/
`binomcoef`/`fast/hypot`/`fast/hypotf` `@param` descriptions,
`gamma-lanczos-sum-expg-scaled` unbalanced parenthesis, `sind` example
spacing, `fast/maxf` stray blank line, and a few missing `@example`
tags and interface doc comments.
This PR addresses the TypeScript declarations (plus the `kernel-betainc`
`lib` JSDoc); the generated namespace aggregator will pick up these
fixes on regeneration. Several findings that are errors replicated
across a package's other doc surfaces (`cscd`, `nonfibonaccif`,
`nonfibonacci`, `powf`) are handled package-wide in a separate PR.
---
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes.
report:
- task: lint_filenames
status: passed
- task: lint_editorconfig
status: passed
- task: lint_markdown_pkg_readmes
status: na
- task: lint_markdown_docs
status: na
- task: lint_markdown
status: na
- task: lint_package_json
status: na
- task: lint_repl_help
status: na
- task: lint_javascript_src
status: passed
- task: lint_javascript_cli
status: na
- task: lint_javascript_examples
status: na
- task: lint_javascript_tests
status: na
- task: lint_javascript_benchmarks
status: na
- task: lint_python
status: na
- task: lint_r
status: na
- task: lint_c_src
status: na
- task: lint_c_examples
status: na
- task: lint_c_benchmarks
status: na
- task: lint_c_tests_fixtures
status: na
- task: lint_shell
status: na
- task: lint_typescript_declarations
status: passed
- task: lint_typescript_tests
status: passed
- task: lint_license_headers
status: passed
---
796b024 to
395f690
Compare
@stdlib/math/base/special declarationsmath/base/special declarations
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This pull request corrects documentation-only issues in TypeScript declaration files across many
@stdlib/math/base/specialpackages, flagged by an audit. No emitted types change in a behavior-affecting way; the edits are limited to TSDoc prose, examples, parameter names/descriptions, and internal interface names.Highlights:
kernel-betainc— the 4th/5th parameters were namedinvert/normalizedwith descriptions swapped relative to the implementationkernelBetainc( x, a, b, regularized, upper ); renamed toregularized/upperwith descriptions re-paired, fixed the garbled "regularized boolean beta function" → "incomplete beta function" (in the declaration and thelib/main.js/lib/assign.jsJSDoc), and fixed the interface doc-comment misspellingkernalBetaInc.gammainc— split the muddledregularized/upperNotes into two clear bullets and fixed a stales <= 0→a <= 0reference.cfloor— summary now reads "Rounds each component of..." like its siblings;cpolarf/sincosd— fixed copy-pasted/lowercase interface names (Cpolar→Cpolarf,sincosd→SinCosd).minmax/minmaxn/minmaxf/sincospi—assign@examples now call the.assignmethod instead of the bare function (sov === outis actuallytrue); corrected theassignsummary/@returnsforsincospi; split merged@exampleblocks.minabs— dropped the empty-set Notes paragraph (the function is binary);minabsn/maxabsn/minmaxabsn— corrected the empty-args identity Notes.covercos/coversin/havercos— added the defining-formula Notes block their forward-trig siblings include.frexp/frexpf"Inteface" typo;absf/acsch/asech/negalucasfsummary wording;floornsummary ("numeric value", matchingceiln/roundn/truncn);cotd/tandtrailing periods;croundunused requires;gammaincinvargument-order notation;lnf/round@returns;truncsd/binomcoef/fast/hypot/fast/hypotf@paramdescriptions;gamma-lanczos-sum-expg-scaledunbalanced parenthesis;sindexample spacing;fast/maxfstray blank line; and a few missing@exampletags and interface doc comments.This PR addresses the TypeScript declarations (plus the
kernel-betainclibJSDoc, to keep that package's fix whole); the generated namespace aggregator will pick up these fixes on regeneration. Several findings that are errors replicated across a package's other doc surfaces —cscd,nonfibonaccif,nonfibonacci,powf— are handled package-wide in a separate PR (#12474). The non-docsfresnelreturn-type narrowing and higher-severityellipj/factorial2ffixes are in their own PRs.Related Issues
No.
Questions
No.
Other
Found via a TypeScript-declaration audit of the
@stdlib/mathnamespace. Several findings were verified against the package implementations (e.g.kernel-betainc,gammainc).Checklist
AI Assistance
If you answered "yes" above, how did you use AI assistance?
Disclosure
These issues were identified by an automated TypeScript-declaration audit run with Claude Code, and the fixes were prepared by Claude Code (with parallel sub-agents per package group) under my review.
@stdlib-js/reviewers