Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[std.algorithm] Improve fold docs #8836

Merged
merged 4 commits into from
Nov 20, 2023
Merged

[std.algorithm] Improve fold docs #8836

merged 4 commits into from
Nov 20, 2023

Conversation

ntrel
Copy link
Contributor

@ntrel ntrel commented Oct 30, 2023

Mention iteratively calling predicates in summary.
Use list to explain calling a single predicate with a seed.
Mention multiple results can be produced in description.
Use list for see also.
Rename seed parameter seeds and fix docs.
Fix result docs when >1 predicate.

Mention iteratively calling predicates in summary.
Use list to explain calling a single predicate with a seed.
Mention multiple results are produced in description.
Use list for see also.
Rename `seed` parameter `seeds` and fix docs.
Fix result docs when >1 predicate.
@dlang-bot
Copy link
Contributor

Thanks for your pull request and interest in making D better, @ntrel! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please verify that your PR follows this checklist:

  • My PR is fully covered with tests (you can see the coverage diff by visiting the details link of the codecov check)
  • My PR is as minimal as possible (smaller, focused PRs are easier to review than big ones)
  • I have provided a detailed rationale explaining my changes
  • New or modified functions have Ddoc comments (with Params: and Returns:)

Please see CONTRIBUTING.md for more information.


If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment.

Bugzilla references

Your PR doesn't reference any Bugzilla issue.

If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog.

Testing this PR locally

If you don't have a local development environment setup, you can use Digger to test this PR:

dub run digger -- build "master + phobos#8836"

@pbackus
Copy link
Contributor

pbackus commented Oct 31, 2023

Should reduce be updated too?

@ntrel
Copy link
Contributor Author

ntrel commented Oct 31, 2023

@pbackus Maybe we can get rid of reduce in std2?

@pbackus
Copy link
Contributor

pbackus commented Oct 31, 2023

@ntrel I hope so, but we're still a long way from std2, and we should probably avoid having two out-of-sync descriptions of the same function in the meantime. If you don't want to repeat the whole thing, maybe we could replace reduce's description with "See fold" and a link?

@dkorpel dkorpel merged commit fe33c84 into dlang:master Nov 20, 2023
18 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants