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

correctly handle CartesianIndex index #41

Merged
merged 1 commit into from
May 15, 2022

Conversation

johnnychen94
Copy link
Contributor

fixes #26

@@ -51,10 +51,13 @@ const .. = Ellipsis()

@inline function to_indices(A, inds::NTuple{M, Any}, I::Tuple{Ellipsis, Vararg{Any, N}}) where {M,N}
# Align the remaining indices to the tail of the `inds`
colons = ntuple(n->Colon(), M-N)
colons = ntuple(n->Colon(), M-_ndims_index(I)+1)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume ArrayInterface.static works nicely with constant 1 and M here?

@codecov-commenter
Copy link

Codecov Report

Merging #41 (876d5a1) into master (22131eb) will not change coverage.
The diff coverage is 100.00%.

@@            Coverage Diff            @@
##            master       #41   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            1         1           
  Lines            6         8    +2     
=========================================
+ Hits             6         8    +2     
Impacted Files Coverage Δ
src/EllipsisNotation.jl 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 22131eb...876d5a1. Read the comment docs.

@ChrisRackauckas ChrisRackauckas merged commit 4ab9aab into SciML:master May 15, 2022
@johnnychen94 johnnychen94 deleted the jc/cartesian branch May 15, 2022 18:16
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.

Elipsis and [CartesianIndex()] not working
3 participants