<div dir="ltr">Just back from vacation.  I'll prepare a patch with a test this afternoon.</div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 15, 2017 at 8:34 AM, David Blaikie <span dir="ltr"><<a href="mailto:dblaikie@gmail.com" target="_blank">dblaikie@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Ping<div><div class="h5"><br><div class="gmail_quote"><div dir="ltr">On Mon, May 8, 2017 at 11:43 AM David Blaikie <<a href="mailto:dblaikie@gmail.com" target="_blank">dblaikie@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Test coverage?</div><br><div class="gmail_quote"><div dir="ltr">On Fri, May 5, 2017 at 10:27 AM Adrian McCarthy via llvm-commits <<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Author: amccarth<br>
Date: Fri May  5 12:14:00 2017<br>
New Revision: 302257<br>
<br>
URL: <a href="http://llvm.org/viewvc/llvm-project?rev=302257&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-<wbr>project?rev=302257&view=rev</a><br>
Log:<br>
Allow operator-> to work from a FixedStreamArrayIterator.<br>
<br>
This is similar to my recent fix for VarStreamArrayIterator, but the cause<br>
(and thus the fix) is subtley different.  The FixedStreamArrayIterator<br>
iterates over a const Array, so the iterator's value type must be const.<br>
<br>
Modified:<br>
    llvm/trunk/include/llvm/<wbr>Support/BinaryStreamArray.h<br>
<br>
Modified: llvm/trunk/include/llvm/<wbr>Support/BinaryStreamArray.h<br>
URL: <a href="http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Support/BinaryStreamArray.h?rev=302257&r1=302256&r2=302257&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-<wbr>project/llvm/trunk/include/<wbr>llvm/Support/<wbr>BinaryStreamArray.h?rev=<wbr>302257&r1=302256&r2=302257&<wbr>view=diff</a><br>
==============================<wbr>==============================<wbr>==================<br>
--- llvm/trunk/include/llvm/<wbr>Support/BinaryStreamArray.h (original)<br>
+++ llvm/trunk/include/llvm/<wbr>Support/BinaryStreamArray.h Fri May  5 12:14:00 2017<br>
@@ -342,7 +342,7 @@ private:<br>
 template <typename T><br>
 class FixedStreamArrayIterator<br>
     : public iterator_facade_base<<wbr>FixedStreamArrayIterator<T>,<br>
-                                  std::random_access_iterator_<wbr>tag, T> {<br>
+                                  std::random_access_iterator_<wbr>tag, const T> {<br>
<br>
 public:<br>
   FixedStreamArrayIterator(<wbr>const FixedStreamArray<T> &Array, uint32_t Index)<br>
@@ -356,6 +356,7 @@ public:<br>
   }<br>
<br>
   const T &operator*() const { return Array[Index]; }<br>
+  const T &operator*() { return Array[Index]; }<br>
<br>
   bool operator==(const FixedStreamArrayIterator<T> &R) const {<br>
     assert(Array == R.Array);<br>
<br>
<br>
______________________________<wbr>_________________<br>
llvm-commits mailing list<br>
<a href="mailto:llvm-commits@lists.llvm.org" target="_blank">llvm-commits@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-commits</a><br>
</blockquote></div></blockquote></div></div></div></div>
</blockquote></div><br></div>