-
-
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
remove duplicate LinearIndices docs #27037
Conversation
Hmm, seems like this was not the full solution, let me investigate. |
@@ -377,7 +377,7 @@ module IteratorsMD | |||
next(iter::Reverse{<:CartesianIndices{0}}, state) = CartesianIndex(), true | |||
done(iter::Reverse{<:CartesianIndices{0}}, state) = state | |||
|
|||
LinearIndices(inds::CartesianIndices{N,R}) where {N,R} = LinearIndices{N,R}(inds.indices) | |||
Base.LinearIndices(inds::CartesianIndices{N,R}) where {N,R} = LinearIndices{N,R}(inds.indices) |
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.
This was a module local function, which was undocumented. Documenter then complained that there were no docs, since we reference this function in the same module (L214).
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 Fredrik! :)
…(::UnitRange{<:Integer})
@deprecate CartesianIndices(inds::Vararg{AbstractUnitRange{Int},N}) where {N} CartesianIndices(inds) | ||
@deprecate CartesianIndices(inds::Vararg{AbstractUnitRange{<:Integer},N}) where {N} CartesianIndices(inds) | ||
@deprecate LinearIndices(inds::Vararg{AbstractUnitRange{Int},N}) where {N} LinearIndices(inds) | ||
@deprecate LinearIndices(inds::Vararg{AbstractUnitRange{<:Integer},N}) where {N} LinearIndices(inds) |
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.
These two LinearIndices
definitions ended up beeing module local without the import
.
CartesianIndices(inds::AbstractUnitRange{Int}) = CartesianIndices(axes(inds)) | ||
CartesianIndices(inds::AbstractUnitRange{<:Integer}) = CartesianIndices(axes(inds)) | ||
LinearIndices(inds::AbstractUnitRange{Int}) = LinearIndices(axes(inds)) | ||
LinearIndices(inds::AbstractUnitRange{<:Integer}) = LinearIndices(axes(inds)) |
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.
Are these definitions correct? Fixes #26775 (comment) at least.
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.
Yes, should be OK to work around the deprecation.
Tests pass locally and doc building works on this branch. Failures are now only #27041 |
Failures are indeed due to |
fix #26775 (comment)