-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Removed default descriptions from multidimensional.jl #23542
Conversation
Removed redundant descriptions along the lines of ```markdown cumsum!(B, A, dim::Integer=1) Cumulative sum of A along a dimension, storing the result in B. **The dimension defaults to 1.** See also cumsum. ```
base/multidimensional.jl
Outdated
@@ -797,8 +796,7 @@ end | |||
""" | |||
accumulate!(op, B, A, dim=1) | |||
|
|||
Cumulative operation `op` on `A` along a dimension, storing the result in `B`. | |||
The dimension defaults to 1. See also [`accumulate`](@ref). | |||
Cumulative operation `op` on `A` along a dimension, storing the result in `B`. See also [`accumulate`](@ref). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps add a linebreak before the second sentence? We try to stay within 92 characters per line, see https://github.com/JuliaLang/julia/blob/master/CONTRIBUTING.md#code-formatting-guidelines
As far as I can tell the dimensions here still default to 1. They shouldn't but they still do. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @Shorty66!
@StefanKarpinski I think you misunderstood what this PR does: it just removes information from the description when it's redundant with the signature.
base/multidimensional.jl
Outdated
@@ -705,15 +704,15 @@ cumprod(A::AbstractArray, axis::Integer=1) = accumulate(*, A, axis) | |||
""" | |||
cumprod!(B, A, dim::Integer=1) | |||
|
|||
Cumulative product of `A` along a dimension, storing the result in `B`. The dimension defaults to 1. | |||
Cumulative product of `A` along a dimension, storing the result in `B`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Woops, turns out the CI failures are legitimate and related to the trailing space here.
Fair enough, but we need to remove the argument altogether. |
Removed default descriptions which were redundant with the method signature.
E.g.