<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On Aug 16, 2010, at 3:33 AM, Chandler Carruth wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div class="gmail_quote">On Mon, Aug 16, 2010 at 3:21 AM, Abramo Bagnara <span dir="ltr"><<a href="mailto:abramo.bagnara@gmail.com">abramo.bagnara@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Il 16/08/2010 11:48, Chandler Carruth ha scritto:<br>
<div class="im">> On Mon, Aug 16, 2010 at 2:24 AM, Enea Zaffanella <<a href="mailto:zaffanella@cs.unipr.it">zaffanella@cs.unipr.it</a><br>
</div><div><div></div><div class="h5">> <mailto:<a href="mailto:zaffanella@cs.unipr.it">zaffanella@cs.unipr.it</a>>> wrote:<br>
><br>
> I think that, in point 3, Abramo was just referring to the wording<br>
> of the diagnostic, which maybe could be improved.<br>
><br>
><br>
> Sure. I've no problem improving the diagnostic, but I'm not sure what to<br>
> make it. Your first is close though, maybe: "a non-type template<br>
> argument which is the address of an object cannot be surrounded by<br>
> parentheses". I'm leery of using words like "type" because of the<br>
> "non-type" category of template arguments we're dealing with. I'm not<br>
> the best wordsmith though....<br>
<br>
</div></div>Furtherly to exit with a fatal error is a bit overkill for things like<br>
that... do you agree?<br>
</blockquote></div><br><div>As I said in my original post, this being an ExtWarn seems plausible, but I don't personally find it compelling to support this syntax. I think it's actually worthwhile that the standard insists on a differentiated syntax in these two cases for the reason I originally pointed out -- this *isn't* an expression, and it shouldn't be thought of in that context.</div>
<div><br></div><div>Perhaps others disagree, or have some large body of code that uses this extensively (seems rather unlikely to me though...), but either way, the code doesn't conform, and so it should at most be accepted as an extension with appropriate warnings.</div></blockquote><div><br></div><div>This is core issue 773:</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre"> <a href="http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_active.html#773">http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_active.html#773</a></span></div></div><br><div>And the committee is favoring allowing the parentheses. I suggest we make it an ExtWarn in C++98/03 mode, with clearer diagnostic text (if we can).</div><div><br></div><div><span class="Apple-tab-span" style="white-space:pre"> </span>- Doug</div></body></html>