Sure, I could give it a shot this weekend.<br><div class="gmail_quote"><div dir="ltr">On Wed, Mar 30, 2016 at 12:03 PM Erica Sadun &lt;<a href="mailto:erica@ericasadun.com">erica@ericasadun.com</a>&gt; wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><br><div><blockquote type="cite"><div>On Mar 29, 2016, at 11:26 PM, Xiaodi Wu via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" target="_blank">swift-evolution@swift.org</a>&gt; wrote:</div><br><div><span style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">On Tue, Mar 29, 2016 at 7:48 PM, Dave Abrahams &lt;</span><a href="mailto:dabrahams@apple.com" style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px" target="_blank">dabrahams@apple.com</a><span style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">&gt; wrote:</span><br style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><blockquote type="cite" style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><br>on Tue Mar 29 2016, Xiaodi Wu &lt;<a href="http://xiaodi.wu-at-gmail.com" target="_blank">xiaodi.wu-AT-gmail.com</a>&gt; wrote:<br><br><blockquote type="cite">Relatedly, while you&#39;re tackling this big revision:<br><br>I&#39;ve tried to play around with what it would take to write a generic<br>non-error-accumulating striding method, and afaict, it would be<br>enormously cleaner if Strideable types are guaranteed to have + and *<br>(well, Strideable.Stride needs *, to be more accurate),<br></blockquote><br>That should happen automatically, since it conforms to SignedNumber,<br>when we get the Integer protocols updated (project currently on hold while<br>we land this other revision).<br><br><blockquote type="cite">since the iterator needs to be able to compute end = start + iteration<br>* stride.<br></blockquote><br>Don&#39;t you need division too if you&#39;re going to do this?<br></blockquote><br style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">I didn&#39;t seem to ever need division. See attached playground (which</span><br style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">borrows shamelessly from existing code and Erica&#39;s proposal, and which</span><br style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">is written in Swift 2.2 because that&#39;s what I had handy).</span><br style="font-family:Palatino-Roman;font-size:14px;font-style:normal;font-weight:normal;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"></div></blockquote></div><br></div><div style="word-wrap:break-word"><div>Have you considered trying to extend the `<a href="https://github.com/apple/swift/tree/swift-3-indexing-model" target="_blank">swift-3-indexing-model</a>` branch</div><div>at the Swift repo to take the floating point approach into account? Dave A</div><div>is working on a massive overhaul of ranges (including `Countable` items</div><div>and one would presume floating point closed and open intervals as well), </div><div>and I&#39;d love to see better implementations of, for example,  `(x..&lt;y).striding(by:z)`</div><div>happen for Double types.</div><div><br></div><div>I&#39;d be happy to throw a proposal together based on a proof of concept,</div><div>if you had the flexibility to work on the coding.</div></div><div style="word-wrap:break-word"><div><br></div><div>-- Erica</div><div><br></div></div></blockquote></div>