> Isn't the issue of empty ranges really an issue of the range being
right-closed without a way to say it should be right-open? So x..y.. could
mean from x to y, excluding y.

You could frame the issue as open/closed ranges but, given our ranges are
exclusive to integers, the general consensus is to treat integer ranges as
closed because you can flip between them using +1 and -1 (the a..b notation
is also used in math). So I would prefer to approach the problem using
steps, because it is strictly more expressive.

> José, wouldn't this be a backward incompatible introduction?

All code written today will still work. However, if you use the new
features (empty ranges or custom steps), then old code may not process the
range accordingly. So it is backwards compatible, as all of the code
written today still works. You may run into issues only if you use new
features. It is definitely something to keep in mind though.

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-core" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-core/CAGnRm4LTsmN7AkEY5hD7Q4Gcj5NBAYtshRyjpMOzWuz8RNXeaA%40mail.gmail.com.

Reply via email to