feat: add ndarray/base/trues-like#12144
Closed
Planeshifter wants to merge 6 commits into
Closed
Conversation
Adds the `@stdlib/ndarray/base/trues-like` package, which creates an ndarray filled with `true` values and having the same shape and data type as a provided ndarray. Follows the same pattern as `@stdlib/ndarray/base/falses-like`. Also registers `truesLike` in the `@stdlib/ndarray/base` namespace. https://claude.ai/code/session_01PxFKbuUFyEW22kNL6XbQ1p
- Add backticks around `true` in package.json description - Add missing `booleans` keyword; fix keyword ordering to match `falses-like` - Use `@stdlib/ndarray/empty` (non-base) in size benchmarks, matching the established pattern in `falses-like` - Add missing "and" in test tape description strings https://claude.ai/code/session_01PxFKbuUFyEW22kNL6XbQ1p
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.
Resolves stdlib-js/todo#2777.
Description
This pull request:
@stdlib/ndarray/base/trues-likepackage, which creates an ndarray filled withtruevalues and having the same shape and data type as a provided input ndarraytruesLikein the@stdlib/ndarray/basenamespaceThe implementation follows the same pattern as
@stdlib/ndarray/base/falses-like:Supported dtypes:
boolandgeneric(same as@stdlib/ndarray/base/truesand@stdlib/ndarray/base/falses-like).Related Issues
This pull request has the following related issues:
Questions
No.
Other
No.
Checklist
AI Assistance
If you answered "yes" above, how did you use AI assistance?
Disclosure
This PR was written primarily by Claude Code.
@stdlib-js/reviewers
Generated by Claude Code