<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On 9 June 2017 at 07:13, Tim Northover via cfe-dev <span dir="ltr"><<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 9 June 2017 at 02:07, Puneetha K via llvm-dev<br>
<span class=""><<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br>
> __auto_type *p = (int *) 0;<br>
><br>
> This compiles with no problem, but GCC gives an error that we can only use<br>
> plain identifier as a declarator.<br>
<br>
</span>At the very least Clang's behaviour is consistent with "auto" in C++,<br>
which I think is a good thing.</blockquote><div><br></div><div>If someone wanted to put a patch together, it would seem reasonable to issue a -Wgcc-compat warning on cases that we know GCC rejects. (We also don't quite follow the GCC semantics: per GCC's documentation, an __auto_type variable is not in scope in its own initializer, whereas Clang's approach makes it an error to name the variable within its initializer, like 'auto' in C++. But at least that means we reject a superset of what GCC rejects.)</div></div></div></div>