On Wed, Aug 4, 2010 at 6:21 PM, Sebastian Redl
<[email protected]> wrote:
> Author: cornedbee
> Date: Wed Aug  4 20:21:19 2010
> New Revision: 110295
>
> URL: http://llvm.org/viewvc/llvm-project?rev=110295&view=rev
> Log:
> Drop an unjustified limitation from Type::isObjectType(). Fixes PR7801 and 
> doesn't seem to break anything.

This does have other effects...

Now accepted:
template<int(*foo)[]> void f() {}
(Also accepted by gcc and comeau.)

Now accepted:
struct t { typedef int (*foo)[]; operator foo(); }; void g() { t o; delete o; }
(Rejected by gcc, accepted by comeau.)

Now rejected:
struct s { typedef int (*foo)[]; operator foo&(); operator int*&(); };
void f() { s o; ++o; }
(Rejected by gcc, accepted by comeau.)

I think clang is behaving correctly, but I'd like some confirmation,
and it might be a good idea to add tests.

-Eli

_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to