JuliaArrays / JuliaArrays/FillArrays.jl

Why is `IndexStyle` specialized for `Base.OneTo`?

Open
#195 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Julia
Stars
187
Forks
41
Avg merge
17h 29m
Merged PRs (30d)
1

Description

https://github.com/JuliaArrays/FillArrays.jl/blob/de36a50a171a4f871d689762ba7886198dd96923/src/FillArrays.jl#L59

This means

julia> using StaticArrays

julia> f = Fill(1, (SOneTo(2),))
2-element Fill{Int64, 1, Tuple{SOneTo{2}}} with indices SOneTo(2), with entries equal to 1

julia> IndexStyle(f)
IndexCartesian()

This may use linear indexing as well, though.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at src/FillArrays.jl around line 59 and reproduce the IndexStyle example using Fill and SOneTo. Determine whether the current specialization intentionally excludes linear indexing, and establish the expected IndexStyle result before changing behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
data
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.