Michael Zedeler wrote:
This is exactly why I keep writing posts about Ranges being defunct as they have been specified now. If we accept the premise that Ranges are supposed to define a kind of linear membership specification between two starting points (as in math), it doesn't make sense that the LHS has an additional constraint (having to provide a .succ method). All we should require is that both endpoints supports comparison (that they share a common type with comparison, at least).

Yes, I agree 100%. All that should be required to construct a range "$foo..$bar" is that the endpoints are comparable, meaning "$foo cmp $bar" works. Having a .pred or .succ for $foo|$bar should not be required to define a range but only to use that range as a generator. -- Darren Duncan

Reply via email to