Skip to content

Deprecate +(::CartesianIndex, ::Number) #26227

Closed
@dlfivefifty

Description

This seems inconsistent:

julia> CartesianIndex((1,2)) + 1 # NO deprecation warning
CartesianIndex(2, 3)

julia> [1,2] + 1 # deprecation warning
┌ Warning: `a::AbstractArray + b::Number` is deprecated, use `broadcast(+, a, b)` instead.
│   caller = top-level scope
└ @ Core :0
2-element Array{Int64,1}:
 2
 3

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Labels

deprecationThis change introduces or involves a deprecation

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions