Strange behavior of Range object

Hello, I am wondering why a “potentially” empty (when collected) range such as 10:1 is echoed differently (although equivalently empty)

julia> 10:1
10:9

S.

See Strange behavior of intersect() when applied to ranges - #9 by StefanKarpinski for a previous discussion.

This might change soon: RFC: preserve end point of empty ranges by vtjnash · Pull Request #43058 · JuliaLang/julia · GitHub

1 Like