-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Closed
Labels
arrays[a, r, r, a, y, s][a, r, r, a, y, s]bugIndicates an unexpected problem or unintended behaviorIndicates an unexpected problem or unintended behavior
Description
This looks like a long-buried bug, recently identified on discourse:
julia> isassigned(zeros(161,517), 500, 514) # should be false
trueThe problem is that the isassigned code is checking only the linear index and not the multidimensional index, which is sufficient to prevent a crash but insufficient to check bounds for multidimensional indices.
cc @timholy, since this code originated in #11167, and @yuyichao who optimized this code (but did not change the semantics) in #20890.
Metadata
Metadata
Assignees
Labels
arrays[a, r, r, a, y, s][a, r, r, a, y, s]bugIndicates an unexpected problem or unintended behaviorIndicates an unexpected problem or unintended behavior