<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">  template<typename T, size_t N><br>
   ArrayRef<T> makeArrayRef(const T (&Arr)[N]) {<br>
-    return Arr;<br>
+    return ArrayRef<T>(Arr, N);<br>
   }<br></blockquote><div><br></div><div>If you're going to implement this specialization this way you could probably just remove the ArrayRef(const T(&)[N]) ctor entirely since no one should/will ever use it. Alternatively would "return ArrayRef<T>(Arr)" avoid the pointer degeneration? (& if that ctor doesn't work correctly (even if it's just because of a misimplementation* on a mainstream compiler) implicitly, should we just mark it explicit to be on the safe side?)<br>
<br>* is this a bug in GCC? filed somewhere?</div></div>