<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jun 30, 2017 at 5:56 AM, Nicolas Cellier <span dir="ltr"><<a href="mailto:nicolas.cellier.aka.nice@gmail.com" target="_blank">nicolas.cellier.aka.nice@gmail.com</a>></span> wrote:</div><div class="gmail_quote"><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>"peekBack deceived"<br></div></div></div></blockquote><div><br></div><div>Strangely, I can't shake the idea this is a good name for a SciFi Thriller movie.</div><div>cheers -ben </div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><a href="http://lists.squeakfoundation.org/pipermail/squeak-dev/2014-July/179285.html" target="_blank">http://lists.squeakfoundation.<wbr>org/pipermail/squeak-dev/2014-<wbr>July/179285.html</a><br><br></div>we can't reasonnably drag too many of these inconsistencies...<div><div class="h5"><br><div><div><div><div><div class="gmail_extra"><br><div class="gmail_quote">2017-06-22 5:48 GMT+02:00 Ben Coman <span dir="ltr"><<a href="mailto:btc@openinworld.com" target="_blank">btc@openinworld.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">When I read that first line of your post, my impression/expectation was the same as yours. <br><div class="gmail_extra">Intuitively #back and #peekBack should return the same value.</div><div class="gmail_extra">But my comments are face-value only, without a deep familiarity of streams.  Maybe someone else can provide historical & future context.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Presuming it was broadly accepted this "should" be the behaviour of #peekBack, the problem with changing its behaviour is the effect on existing users, and also cross-dialect compatability. "Ideally" Squeak/Cuis would be ammendable to such a change, and then one approach could be a little dance using an interim #peekBackFromCursor so the existing #peekBack can be deprecated for one version (to avoid silent corruption of application logic) then restoring #peekBack with the new behaviour.    A slow process, but such small changes accumulate over time to improve things.</div><div class="gmail_extra"><br></div><div class="gmail_extra">Alternatively, we just leave #peekBack as-is and permanently introduce #peekBackFromCursor or similar.  </div><div class="gmail_extra">Maybe such changes would be superseded by XStreams anyway (not really a reason stop improving current system anyway.)<br></div><div class="gmail_extra"><br></div><div class="gmail_extra">cheers -ben</div><div><div class="m_-7798372165301630054gmail-h5"><div class="gmail_extra"><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Jun 21, 2017 at 9:00 PM, Jakob Reschke <span dir="ltr"><<a href="mailto:jakob.reschke@student.hpi.de" target="_blank">jakob.reschke@student.hpi.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi all,<br>
<br>
I just stumbled upon the behavior of #peekBack. I expected that it<br>
would give me a "preview" of what I would get when I send #back, but<br>
without changing the position of the Stream (like #peek does for<br>
#next). Or in other words, I expected to get the last read (or<br>
written) element.<br>
<br>
As it turned out it answers the next-to-last element instead. There<br>
even is a test case in RWBinaryOrTextStreamTest for this behavior.<br>
<br>
But does it make sense? I have my doubts mainly because of the<br>
inconsistency with the return value of #back.<br>
<br>
There is also #peekLast, which does what I expected, but it is only<br>
defined for File- and WriteStream and the comment says it is intended<br>
to get the last put element, not a last read/extracted/next-ed<br>
element.<br>
<br>
Kind regards,<br>
Jakob<br>
<br>
</blockquote></div><br></div></div></div></div>
<br><br>
<br></blockquote></div><br></div></div></div></div></div></div></div></div>
<br><br>
<br></blockquote></div><br></div></div>